PHPackages                             nitier/framework - 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. nitier/framework

ActiveLibrary

nitier/framework
================

A PHP framework for building web applications.

v0.6.2(5mo ago)015PHPPHP ^8.4

Since Sep 29Pushed 5mo agoCompare

[ Source](https://github.com/Nitier/Framework)[ Packagist](https://packagist.org/packages/nitier/framework)[ RSS](/packages/nitier-framework/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (2)Dependencies (10)Versions (4)Used By (0)

Nitier Framework
================

[](#nitier-framework)

Minimalist PHP 8.4 framework that embraces the PSR ecosystem while keeping the core tiny. Features:

- PSR-7 HTTP messages and PSR-15 middleware pipeline
- Attribute-based routing and DI powered by PHP-DI
- Reusable response helpers (JSON, HTML, redirect, etc.)
- Debug overlay for HTML responses in dev mode
- Optional session and cookie utilities
- Example application under `examples/test-app/` and comprehensive docs under `docs/`

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

[](#installation)

```
composer require nitier/framework
```

Or clone the repository for development:

```
git clone https://github.com/nitier/framework.git
cd framework
composer install
```

Quick Start
-----------

[](#quick-start)

1. Copy `examples/test-app/` as a starting point or require the package in your existing project.
2. In `public/index.php` bootstrap the kernel and point to your app directory:

```
use Framework\Kernel;

require __DIR__ . '/../vendor/autoload.php';

$kernel = new Kernel();
$kernel->loadApplication(__DIR__ . '/../examples/test-app');
$kernel->handle();
```

3. Add routes/controllers under `examples/test-app/src/Http/Controller/` using attribute routes:

```
use Framework\Http\Routing\Attribute\Route;
use Framework\Http\Message\JsonResponse;

class ApiController
{
    #[Route(methods: ['GET'], path: '/api/status')]
    public function status(): JsonResponse
    {
        return new JsonResponse(['status' => 'ok']);
    }
}
```

4. Configure global middleware, services, and settings via PHP files inside `config/` and your app's `config/` directory.

Session &amp; Cookie Helpers
----------------------------

[](#session--cookie-helpers)

```
use Framework\Http\Session\SessionManager;
use Framework\Http\Cookie\CookieJar;

$session = new SessionManager();
$session->set('user_id', 42);

$cookies = new CookieJar();
cookies->queue('token', 'abc', ['httpOnly' => true]);
```

Add `StartSessionMiddleware` and `CookieQueueMiddleware` to your global middleware list to automate lifecycle management.

Debug Mode
----------

[](#debug-mode)

Enable debug by storing `kernel.mode.debug => true` in the container. HTML responses will include a floating diagnostic panel with request attributes, environment snapshot, and metrics.

Testing &amp; Quality
---------------------

[](#testing--quality)

- `composer test`
- `composer cs`
- `composer stan`

All tests run inside PHPUnit; some session tests use isolated processes.

Documentation
-------------

[](#documentation)

Extensive docs live in the `docs/` directory covering routing, middleware, responses, templates, sessions, and testing. View them online or serve them using the example app at `/docs`.

License
-------

[](#license)

MIT License. See `LICENSE` for details.

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance70

Regular maintenance activity

Popularity6

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity45

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 ~30 days

Total

3

Last Release

170d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/d1699f8ad2da82ebad82eb74d3392f6989ba9f1d903ee06410f861881af5fade?d=identicon)[Nitier](/maintainers/Nitier)

---

Top Contributors

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

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/nitier-framework/health.svg)

```
[![Health](https://phpackages.com/badges/nitier-framework/health.svg)](https://phpackages.com/packages/nitier-framework)
```

###  Alternatives

[neos/flow

Flow Application Framework

862.0M451](/packages/neos-flow)[neos/flow-development-collection

Flow packages in a joined repository for pull requests.

144179.3k3](/packages/neos-flow-development-collection)[cakephp/authentication

Authentication plugin for CakePHP

1153.6M67](/packages/cakephp-authentication)[flarum/core

Delightfully simple forum software.

211.3M1.9k](/packages/flarum-core)[eliashaeussler/typo3-warming

Warming - Warms up Frontend caches based on an XML sitemap. Cache warmup can be triggered via TYPO3 backend or using a console command. Supports multiple languages and custom crawler implementations.

20229.9k](/packages/eliashaeussler-typo3-warming)[rareloop/lumberjack-core

A powerful MVC framework for the modern WordPress developer. Write better, more expressive and easier to maintain code

42155.0k19](/packages/rareloop-lumberjack-core)

PHPackages © 2026

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