Programster's Blog

Tutorials focusing on Linux, programming, and open-source

Create Symfony Project

Even though the command has skeleton in it, it looks pretty heavy from the number of packages it includes.

composer create-project symfony/website-skeleton my-web-project

When you try to run it with either php -S -t public or bin/console server:run you will be shown an error page, so either your expected to configure something differently immediately, or something went wrong.

4.x API or CLI Application (LTS)

If you want to install a more stripped down version of symfony for a CLI tool or API, then you can use this instead.

composer create-project symfony/skeleton my-api-or-cli-tool

You can quickly see the framework running by navigating to within the project directory and running:

php -S localhost:8000 -t public

... before then navigating to inside your web browser.

Last updated: 16th September 2021
First published: 16th August 2018