Go from idea to launch with clean and elegant PHP that grows with you. With a zero-config setup and an ecosystem of powerful tools, Leaf helps you build and ship scalable apps—fast
$ composer global require leafs/cli -W
$ leaf create app-name
$ cd app
Leaf is built for makers who move fast. With no config and effortless deployment, you can run Leaf anywhere PHP is available—no questions asked. Shared hosting? Just drag and drop. Cloud or VPS? Seamless. Get from idea to production in no time.
Leaf provides lightweight, customizable tools designed to help you to build, ship, and scale—without unnecessary complexity. Now, you can quickly go from idea to profitable product.
Sign users in or create accounts using Leaf's Auth module:
auth()->login([...]);
Leaf will automatically handle the authentication process, including hashing passwords and storing user + sessions and JWTs. You can also protect your routes with Leaf's middleware.
app()->get('/login', ['middleware' => 'auth.required', function () {
// this route is only accessible to logged in users
}]);
From account verification to roles and permissions, Leaf Auth gives you a ton of features right out of the box. Check out the authentication documentation.
Today’s web development landscape demands tools that are fast, lightweight, and capable of growing with your projects. Many PHP frameworks try to do it all, making it challenging to find one that truly checks all these boxes—often adding unnecessary complexity to projects that need to stay nimble. That’s where Leaf shines. It gives the essentials to start building right away, with the flexibility to add exactly the features you need, precisely when you need them.
Thanks for making this! I have been looking for an alternative to Silex for a few years now. I have tried other frameworks like Lumen, Laravel & Slim, but they were always a pain to setup with my VMs, and usually forced you to adhere to a console generated bundle.
As a design/frontend-heavy agency, we needed a lightweight, but powerful framework that would just work on our servers without any hassle. Leaf has been a great choice for us as it allows us to build our APIs really fast, giving us time to focus on what we want: the design and experience of our projects.
Awesome, I just found about it and already using it for a client's site.Clean, well organized and the MVC versión is just great!!!
Building with Leaf has been the most simple and straightforward approach to getting an app production ready
I'm currently looking for a framework to replace our in-house built MVC framework which we have spent quite some time building over the years. I just don't "get" the major frameworks and to me I want something simple which I can add to if needed and now I come across Leaf. Wow. I think you've done a great job! ... Thanks!
“I don’t have time for complexity. Leaf gives me the tools I need, nothing more.”
We’ve said enough about Leaf and what it can do. Why don’t you try changing the code below and see what you can create. If you want to follow a guided tutorial in our sandbox, you can check out the interactive tutorial 🏄♀
Go to tutorialLeaf is fully community backed. Your support goes a long way to help us keep Leaf running and keep up with the demand associated with the growth of our tools. Here are our current sponsors ❤️
Our first community meet up was in 2023 which we held together with SeevCash. Since then our community has gotten bigger, growing together with Leaf and all the tools in the ecosystem. Join our young but vibrant community and the Leaf team as we discuss our insights from the past year and what’s to come in the next couple of years 🚀
Join the communityThese are the heroes who have made Leaf what it is today. We are grateful for their contributions and support ❤️
Leaf is a slim and lightweight PHP framework focused on developer experience, usability, and high-performance code. It is a modern PHP framework built to be simple and elegant, yet extremely powerful.