PHPackages                             jc-it/yii2-maintenance-mode - 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. jc-it/yii2-maintenance-mode

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

jc-it/yii2-maintenance-mode
===========================

Maintenance mode implementation for Yii2

v1.2.0(3mo ago)171MITPHPPHP &gt;=8.0

Since Dec 24Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/JC-IT/yii2-maintenance-mode)[ Packagist](https://packagist.org/packages/jc-it/yii2-maintenance-mode)[ RSS](/packages/jc-it-yii2-maintenance-mode/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (1)Versions (4)Used By (0)

Maintenance mode for Yii2
=========================

[](#maintenance-mode-for-yii2)

This extension provides a maintenance mode implementation for Yii2.

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

[](#installation)

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

Either run

```
$ composer require jc-it/yii2-maintenance-mode
```

or add

```
"jc-it/yii2-maintenance-mode": "^"

```

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

Configuration
-------------

[](#configuration)

- Add maintenance mode as component

```
...
'bootstrap' => ['maintenance'],
'components' => [
    'maintenance' => [
        'class' => \JCIT\maintenance\components\MaintenanceMode::class,
    ],
],
```

- Add the console controller

```
class MaintenanceController extens \JCIT\maintenance\controllers\Maintenance
```

- Add a Maintenance action to your SiteController (i.e.)

```
class SiteController extends \yii\web\Controller
{
    public function actions(): array
    {
        return [
            'maintenance' => \JCIT\maintenance\actions\Maintenance::class,
        ];
    }
}
```

Usage
-----

[](#usage)

To enable maintenance mode, run the `maintenance/enable` console command with optionally a duration and message.

```
src/yii maintenance/enable --message "We are performing maintenance." --duration 3600

```

To extend the duration of the maintenance mode use the `maintenance/extend` console command.

```
src/yii maintenance/extend --duration 3600

```

To add an update to the maintenance mode use the `maintenance/update` console command.

```
src/yii maintenance/update --message "Maintenance update"

```

To disable maintenance mode, run the `maintenance/disable` console command.

```
src/yii maintenance/disable

```

TODO
----

[](#todo)

- Add tests

Credits
-------

[](#credits)

- [Joey Claessen](https://github.com/joester89)
- [HeRAMS WHO](https://github.com/HeRAMS-WHO)
- [Sam Mousa](https://github.com/SamMousa)

###  Health Score

41

—

FairBetter than 89% of packages

Maintenance79

Regular maintenance activity

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity57

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

Every ~748 days

Total

3

Last Release

111d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/88359ebe0456645a614e563dfbf0dd025b69ef57221050cb9eb31e3eef4dd0f9?d=identicon)[joester89](/maintainers/joester89)

---

Top Contributors

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

### Embed Badge

![Health badge](/badges/jc-it-yii2-maintenance-mode/health.svg)

```
[![Health](https://phpackages.com/badges/jc-it-yii2-maintenance-mode/health.svg)](https://phpackages.com/packages/jc-it-yii2-maintenance-mode)
```

###  Alternatives

[dmstr/yii2-cookie-consent

Yii2 Cookie Consent Widget

1452.6k](/packages/dmstr-yii2-cookie-consent)

PHPackages © 2026

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