Symfony is a set of reusable PHP components and a framework to build web applications, APIs and console tools. It has powered millions of projects for more than 20 years, from personal sites to some of the largest platforms on the web, and its components are the foundation of many other major PHP projects. Here is the whole pitch, in five minutes.
No installers and no scaffolding wizards. One Composer command creates a minimal application that you grow as needed:
1 2 3
$ composer create-project symfony/skeleton my_project
$ cd my_project
$ symfony server:start
A route, a controller and a response. Explicit, typed PHP code with no magic globals, where attributes keep the configuration next to the code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
namespace App\Controller;
use Symfony\Component\HttpFoundation\Response;
use Symfony\Component\Routing\Attribute\Route;
class LuckyController
{
#[Route('/lucky/number')]
public function number(): Response
{
$number = random_int(0, 100);
return new Response("<html><body>Lucky number: $number</body></html>");
}
}
Your project only contains what it uses. When you need a feature, install it and Symfony configures it for you: an ORM, a mailer, queues, real-time UIs, security, an HTTP client, schedulers, notifications and much more:
1 2 3
$ composer require orm
$ composer require mailer
$ composer require symfony/ux-live-component
- Predictable releases: a new version every six months, with long-term support releases maintained for years;
- A backward compatibility promise: upgrades are smooth and deprecations warn you long before anything breaks;
- Best-in-class developer experience: the profiler and debug toolbar, detailed error pages and code generators;
- An enormous ecosystem: thousands of open source bundles and packages, professional support, certifications and conferences around the world;
- One of the largest PHP communities: thousands of contributors and extensive documentation.
Convinced enough to spend half an hour? The interactive Quick Tour walks you through the Symfony essentials, no installation required.