Menu
User

DropVPS Team

Writer: Cooper Reagan

How to Install Symfony on Debian 13 (Trixie)

How to Install Symfony on Debian 13 (Trixie)

Publication Date

10/22/2025

Category

Articles

Reading Time

3 Min

Table of Contents

Symfony is one of the most powerful and flexible PHP frameworks available for modern web development. It offers high performance, reusable components, and an organized structure that makes it ideal for both small projects and enterprise-grade applications.

Update Your System

Start by updating your Debian 13 packages to ensure compatibility and stability:

sudo apt update && sudo apt upgrade -y

Install PHP and Required Extensions

Symfony requires PHP 8.2 or higher. Debian 13 includes updated repositories, so you can install the latest version directly:

sudo apt install php php-cli php-common php-mbstring php-xml php-zip php-curl php-intl php-sqlite3 unzip git -y

Check that PHP is installed and confirm the version:

php -v

You should see output similar to:
PHP 8.2.x (cli) (built: …)

Install Composer

Composer is PHP’s dependency manager and is required to install Symfony and its packages.

Run the following commands to install it globally:

php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');"
php composer-setup.php
sudo mv composer.phar /usr/local/bin/composer
php -r "unlink('composer-setup.php');"

Verify the installation:

composer --version

Install Symfony CLI

The Symfony CLI simplifies the process of creating, managing, and running Symfony applications.

Install it using the following command:

wget https://get.symfony.com/cli/installer -O - | bash

Move the Symfony binary to your PATH so it’s available system-wide:

sudo mv ~/.symfony*/bin/symfony /usr/local/bin/symfony

Check if it’s working:

symfony -v

Create a New Symfony Project

Once everything is installed, you can create a new Symfony project. Run:

symfony new my_project --webapp

This will generate a new Symfony application with the default directory structure and dependencies.

Navigate into the project folder:

cd my_project

Run the Symfony Development Server

Symfony provides a local web server via its CLI. You can start it using:

symfony serve

If all is configured properly, you’ll see something like:

[OK] Web server listening on https://127.0.0.1:8000

Now open your browser and visit:
👉 https://127.0.0.1:8000

You should see the Symfony Welcome Page.

Fix File Permissions (If Needed)

If you run into cache or log permission issues, set ownership of your project directory:

sudo chown -R $USER:$USER ~/my_project

Deploying Symfony (Optional)

If you plan to serve your application publicly, install Apache or Nginx.

For Apache:

sudo apt install apache2 libapache2-mod-php -y
sudo systemctl enable apache2
sudo systemctl start apache2

Place your Symfony project inside /var/www/html/ and configure a virtual host for your domain.

Installing Symfony on Debian 13 (Trixie) gives you a complete PHP development environment ready for scalable, secure, and modern web applications. Symfony’s structure, performance, and developer tooling make it one of the best frameworks for building professional web projects.

For high-speed Debian VPS servers optimized for Symfony, Laravel, and other PHP frameworks, visit DropVPS — reliable hosting for developers and production environments.

Linux VPS
U
Loading...

Related Posts