PHPackages                             deepn9x/yii2-env - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. deepn9x/yii2-env

ActiveYii2-extension[Utility &amp; Helpers](/categories/utility)

deepn9x/yii2-env
================

DOT-ENV

1.0.1(2y ago)05MITPHP

Since Jan 29Pushed 2y ago1 watchersCompare

[ Source](https://github.com/deepn9x/yii2-env)[ Packagist](https://packagist.org/packages/deepn9x/yii2-env)[ RSS](/packages/deepn9x-yii2-env/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (1)Versions (2)Used By (0)

DOT-ENV
=======

[](#dot-env)

DOT-ENV

Installation
------------

[](#installation)

The preferred way to install this extension is through [composer](http://getcomposer.org/download/).

create .env file to config folder

First add link to composer.json

```
{
  "type": "git",
  "url": "https://github.com/deepn9x/yii2-env"
}

```

Either run

```
composer require deepn9x/yii2-env

```

or add

```
"deepn9x/yii2-env": "1.0"

```

to the require section of your `composer.json` file.

Usage
-----

[](#usage)

Once the extension is installed, simply use it in your code by :

```
```

or add to web.php
in components
```

'dotenv' =&gt; \[ 'class' =&gt; deepn9x\\env\\dotenv::class \],

```

Using examples
$example_1 = Yii::$app->dotenv->key("KEY");
$example_2 = new dotenv("ISP_KEY");

```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

834d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8471433dba12b4ed46f6f35d6a5661caf74d01046e7d0ed40e4ac5de1f967a83?d=identicon)[deepn9x](/maintainers/deepn9x)

---

Top Contributors

[![deepn9x](https://avatars.githubusercontent.com/u/105905442?v=4)](https://github.com/deepn9x "deepn9x (55 commits)")

---

Tags

pluginyii2extensionYii2 .env class

### Embed Badge

![Health badge](/badges/deepn9x-yii2-env/health.svg)

```
[![Health](https://phpackages.com/badges/deepn9x-yii2-env/health.svg)](https://phpackages.com/packages/deepn9x-yii2-env)
```

###  Alternatives

[kartik-v/yii2-widget-colorinput

An enhanced Yii 2 widget encapsulating the HTML 5 color input (sub repo split from yii2-widgets)

324.8M10](/packages/kartik-v-yii2-widget-colorinput)[daixianceng/yii2-smser

Yii2 SMS extension

862.9k1](/packages/daixianceng-yii2-smser)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
