PHPackages                             larafony/core - 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. [Framework](/categories/framework)
4. /
5. larafony/core

ActiveLibrary[Framework](/categories/framework)

larafony/core
=============

Larafony is a modern PHP 8.5 framework combining the elegance of Laravel, the stability of Symfony, and the power of PSR standards - built for production, not tutorials. Minimal dependencies, full PSR support, custom middleware stack, and analytics without cookies or Google.

2.2.0(3mo ago)8951115MITPHPPHP &gt;=8.5CI passing

Since Oct 5Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/DJWeb-Damian-Jozwiak/larafony)[ Packagist](https://packagist.org/packages/larafony/core)[ Docs](https://www.larafony.com)[ RSS](/packages/larafony-core/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (7)Dependencies (15)Versions (37)Used By (5)

Larafony
========

[](#larafony)

[![Larafony Logo](logo.png)](logo.png)

**Larafony** is a modern, lightweight PHP framework that combines the **developer experience of Laravel**, the **robustness of Symfony**, and the **power of PHP 8.5** — all without compromise.
It’s designed for **production-grade applications**, not tutorials or demos.

---

✨ Key Features
--------------

[](#-key-features)

- **⚙️ Built on PSR Standards**
    Full support for **PSR-7 (HTTP)**, **PSR-11 (Container)**, **PSR-15 (Middleware)**, and **PSR-3 (Logger)**.
    Interoperability at its core — use any compliant library or component you prefer.
- **🧩 Attribute-Based Design**
    Fully powered by **PHP Attributes**, bringing clean syntax and native reflection instead of verbose annotations or configuration files.
- **🔓 Not Locked into One Ecosystem**
    You’re free to choose your tools. Larafony works seamlessly with:

    - **Inertia.js**
    - **Vue.js**
    - **Blade**
    - **Twig**
- **🪶 Minimal Dependencies**
    A **minimal `composer.json`** — PSR packages only. No unnecessary framework bloat.
- **🧱 Custom Middleware Stack**
    A powerful yet simple **middleware pipeline**, inspired by PSR-15 and fine-tuned for performance.
- **📊 Built-in Backend Analytics**
    Privacy-friendly, **cookie-free analytics**, with no dependence on Google or external trackers.

---

🚀 Philosophy
------------

[](#-philosophy)

> **Larafony** exists for developers who love the elegance of Laravel, the discipline of Symfony, and the freedom of pure PHP.
> It’s opinionated where it matters — and unopinionated everywhere else.

- **Production-ready from day one**
- **Framework-agnostic mindset**
- **Performance-first architecture**
- **Readable, modern PHP code**

---

🧰 Requirements
--------------

[](#-requirements)

- PHP ≥ 8.5
- Composer 2.9+
- PSR-compliant HTTP and container packages (installed automatically)
- OpenSSL enabled
- extensions enabled: `curl`, `mbstring`,`pdo`, `uri`, `xml`

⚠️ If you see deprecation warnings during `composer create-project`, run:

```
composer self-update
```

❗Running Larafony on older PHP / Composer versions is **not supported**and issues caused by outdated environments will be closed without investigation.

### Docker Alternative

[](#docker-alternative)

For a containerized development environment:

- Docker ≥ 20.10
- Docker Compose ≥ 2.0

See [DOCKER.md](DOCKER.md) for complete Docker setup and usage instructions.

🧭 Roadmap
---------

[](#-roadmap)

> Each chapter is developed in a separate branch and includes unit tests using PHPUnit.

### 🧩 Core Foundation

[](#-core-foundation)

- Base framework configuration — [Chapter 1](docs/Larafony/chapter1.md)
- Simple error handling — [Chapter 2](docs/Larafony/chapter_2.md)
- Simple timer using PSR-20 (Simple Carbon replacement) — [Chapter 3](docs/Larafony/chapter_3.md)
- HTTP requests with PSR-7/PSR-17 (Simple Web Kernel) — [Chapter 4](docs/Larafony/chapter_4.md)
- Dependency Injection using PSR-11 — [Chapter 5](docs/Larafony/chapter_5.md)

### 🌐 HTTP Layer

[](#-http-layer)

- Routing using PSR-15 — [Chapter 6](docs/Larafony/chapter_6.md)
- HTTP client using PSR-18 (Simple Guzzle replacement) — [Chapter 7](docs/Larafony/chapter_7.md)
- Environment variables and configuration — [Chapter 8](docs/Larafony/chapter_8.md)

### ⚙️ Console &amp; Databasechap

[](#️-console--databasechap)

- Console Kernel — [Chapter 9](docs/Larafony/chapter_9.md)
- MySQL Schema Builder — [Chapter 10](docs/Larafony/chapter_10.md)
- MySQL Query Builder — [Chapter 11](docs/Larafony/chapter_11.md)
- MySQL Migrations — [Chapter 12](docs/Larafony/chapter_12.md)
- ORM (ActiveRecord with Property Observers) — [Chapter 13](docs/Larafony/chapter_13.md)

### 🧱 Application Layer

[](#-application-layer)

- Logging System (PSR-3) — [Chapter 14](docs/Larafony/chapter_14.md)
- Middleware System (PSR-15) + Advanced routing — [Chapter 15](docs/Larafony/chapter_15.md)
- DTO-based Form Validation — [Chapter 16](docs/Larafony/chapter_16.md)

### 🎨 View Layer (simple)

[](#-view-layer-simple)

- Custom Blade Parser — [Chapter 17](docs/Larafony/chapter_17.md)

### 🌐 Migrating to packagist

[](#-migrating-to-packagist)

- Demo application as a separate project — [Chapter 18](docs/Larafony/chapter_18.md)

### 🎨 View Layer (SPA)

[](#-view-layer-spa)

- Inertia.js Middleware (Vue.js) — [Chapter 19](docs/Larafony/chapter_19.md)

### 💥 Error Handling

[](#-error-handling)

- Advanced Web Error Handling — [Chapter 20](docs/Larafony/chapter_20.md)
- Advanced Console Error Handling — [Chapter 21](docs/Larafony/chapter_21.md)

### 🔐 Security &amp; Communication

[](#-security--communication)

- Encrypted Cookies and Sessions — [Chapter 22](docs/Larafony/chapter_22.md)
- Sending Emails — [Chapter 23](docs/Larafony/chapter_23.md)
- Authorization System — [Chapter 24](docs/Larafony/chapter_24.md)
- Cache Optimization (PSR-6) — [Chapter 25](docs/Larafony/chapter_25.md)
- Event System (PSR-14) — [Chapter 26](docs/Larafony/chapter_26.md)
- Debugbar + Model Eager Loading— [Chapter 27](docs/Larafony/chapter_27.md)
- Jobs and Queues — [Chapter 28](docs/Larafony/chapter_28.md)
- Simple WebSockets (almost from scratch) — [Chapter 29](docs/Larafony/chapter_29.md)
- Model Context Protocol — A new way of communication — Chapter 30

### 🧭 Meta

[](#-meta)

- Why Larafony — Comparing with Laravel, Symfony, CodeIgniter — Chapter 31

### 🧩 The Philosophy of the Final Chapters

[](#-the-philosophy-of-the-final-chapters)

**This will be updated while following packages reach FULL php8.5 support.**

Larafony’s journey doesn’t end with writing code — it ends with understanding.

The last chapters are not about adding features, but about **liberating the developer**.
They show that every component — clock, container, logger, cache, or view — is *optional*, replaceable, and interchangeable.

Each replacement (Carbon, Monolog, Laravel Container, Twig, etc.) isn’t a “plugin”, but a **lesson**:

> how professional PHP code achieves the same result through different abstractions.

By the time you reach the end, you won’t just *use* a framework —
you’ll **understand the architecture behind every framework**.

> "The best framework is the one you can replace piece by piece — because you understand it completely."

---

🧠 **Larafony is not just a framework.**
It’s an open architecture, a teaching tool, and a manifesto of modern PHP.

Every line of code exists to remind you that:

- elegance is a function of simplicity,
- performance is a side effect of clarity, and
- real mastery means knowing when to write less.

Welcome to the end of the framework —
and the beginning of **your own**.

### ⚙️ Extending with mature Libraries

[](#️-extending-with-mature-libraries)

- Larafony bridges - Chapter 32
    - View Bridges (Twig &amp; Smarty)
    - Use Carbon instead of ClockFactory
    - Use Monolog
    - Use Symfony Mailer
    - Use Guzzle Http

🚀 Quick Start
-------------

[](#-quick-start)

### Using Docker (Recommended)

[](#using-docker-recommended)

```
# Quick start - all in one script
./docker-test.sh              # Run tests without coverage
./docker-test.sh --coverage   # Run tests with HTML coverage report

# Or step by step
./docker.sh build             # Build Docker images
./docker.sh up                # Start MySQL service
./docker.sh test              # Run tests
./docker.sh quality           # Run all quality checks
```

**Coverage reports:**

- HTML report: Open `coverage/index.html` in your browser
- Text output: Use `./docker-test.sh --text`

See [DOCKER.md](DOCKER.md) for complete Docker documentation and all available commands.

### Using Local PHP

[](#using-local-php)

```
# Install dependencies
composer install

# Run tests
composer test

# Run quality checks
composer quality
```

🚀 Learn How It's Built—From Scratch
-----------------------------------

[](#-learn-how-its-builtfrom-scratch)

Interested in **how Larafony is built step by step?**

Check out my full PHP 8.5 course, where I explain everything from architecture to implementation — no magic, just clean code.

👉 Get it now at [masterphp.eu](https://masterphp.eu)

Additional Resources
--------------------

[](#additional-resources)

- [PSR Standards](https://www.php-fig.org/psr/)
- [PHPUnit Documentation](https://phpunit.de/)
- [PHPStan Documentation](https://phpstan.org/)
- [Composer Documentation](https://getcomposer.org/doc/)

License

The Larafony framework is open-sourced software licensed under the [MIT license](https://opensource.org/license/MIT).

###  Health Score

50

—

FairBetter than 96% of packages

Maintenance80

Actively maintained with recent releases

Popularity25

Limited adoption so far

Community22

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 98.3% 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 ~14 days

Total

8

Last Release

105d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/41979fa3adf74e308157185e30a99c93795d8bb8c33f35dbcef030cb3c9865c2?d=identicon)[damek24](/maintainers/damek24)

---

Top Contributors

[![damek24](https://avatars.githubusercontent.com/u/11960180?v=4)](https://github.com/damek24 "damek24 (339 commits)")[![blancks](https://avatars.githubusercontent.com/u/1021441?v=4)](https://github.com/blancks "blancks (3 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (2 commits)")[![raphaelstolt](https://avatars.githubusercontent.com/u/48225?v=4)](https://github.com/raphaelstolt "raphaelstolt (1 commits)")

---

Tags

httppsrphpmiddlewarecontainerframeworkbladeinertiaclean codephp8vuemodern

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/larafony-core/health.svg)

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

###  Alternatives

[cakephp/cakephp

The CakePHP framework

8.8k18.5M1.6k](/packages/cakephp-cakephp)[symfony/symfony

The Symfony PHP framework

31.3k86.3M2.2k](/packages/symfony-symfony)[neos/flow

Flow Application Framework

862.0M451](/packages/neos-flow)[shopware/platform

The Shopware e-commerce core

3.3k1.5M3](/packages/shopware-platform)[windwalker/framework

The next generation PHP framework.

25639.1k1](/packages/windwalker-framework)[neos/flow-development-collection

Flow packages in a joined repository for pull requests.

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

PHPackages © 2026

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