MarwaPHP is a fast, lightweight, and modular PHP framework built for modern web development. It simplifies API and application development with expressive routing, powerful CLI tools, and a clean MVC structure — all while staying minimal and extensible.
- ✅ Lightweight MVC structure
- 🔧 CLI tools for rapid scaffolding
- 🛠 Schema Builder, Migrations, and Seeders
- 🔐 JWT Authentication & Middleware
- 🌐 Built-in CORS support
- 📅 Task Scheduling & Queues
- 🧰 Helper functions & Utilities
- 🐳 Docker-ready for scalable deployment
I've been developing PHP projects for over 20 years and have extensively worked with frameworks like CodeIgniter. While these frameworks enabled rapid development, I encountered recurring pain points — frequent breaking changes, bloated general-purpose features, and backward-incompatible updates that rendered many of my projects obsolete. Maintaining legacy code became increasingly difficult as frameworks evolved.
Then came Laravel with a modern and elegant syntax, but it introduced its own challenges: too many built-in features, increased complexity, and unnecessary overhead for lightweight projects.
That’s when I decided to build my own framework — MarwaPHP. It's thoughtfully designed to be lightweight, modular, and efficient, using only the best libraries in the PHP ecosystem. MarwaPHP delivers a Laravel-like developer experience without the bloat, making it ideal for scalable, maintainable, and production-ready applications.
marwa-php/
├── app/ → Application Code (Controllers, Models, Views)
├── config/ → Configuration files
├── public/ → Web root (index.php)
├── routes/ → Route definitions
├── resources/ → Views & Assets
├── database/ → Migrations, Seeders
├── tests/ → Unit & Feature tests
└── vendor/ → Composer packages
# Clone the repo
git clone https://github.com/memran/marwa-php.git
# Enter project directory
cd marwa-php
# Install dependencies
composer install
# Run dev server
php -S localhost:8000 -t public/
Visit the MarwaPHP GitHub Wiki to get started and learn all features:
- Getting Started
- Routing
- Controllers
- Models
- Views (Twig)
- Authentication
- Authorization (Roles & Policies)
- Session Management
- Queue System
- Task Scheduling
- Docker Setup
- 📦 Build a RESTful API in minutes
- 🔐 Secure routes with policies
- 🧠 Schedule background tasks
- 📊 Queue jobs with Redis
- 🧪 Run PHPUnit tests
We welcome contributions! Open an issue, submit a PR, or improve documentation.
MIT © Mohammad Emran