Symfony is a developer-centric PHP framework that powers thousands of websites and web apps today. This framework is built upon Symfony Components that developers mix-and-match to create CMS and platforms such as Drupal, eZ Publish, etc.
The framework is particularly well known for its vibrant community that includes over 2,000 contributors who maintain the Symfony core code and related projects.
Reference: Builtwith, Jan 2021
Such a robust framework needs to be paired with an excellent hosting solution. This is where AWS hosting services excels because it is considered the pioneer in providing cloud infrastructure with persistent performance, reliable server infrastructure, and prompt technical support.
Amazon has data centres at major business locations. As a result, you get the option to host your websites closer to the target audience. Hosting Symfony on an AWS EC2 is not at all difficult. In this tutorial, I’ll show you that you can install Symfony on AWS using Cloudways Platform within minutes.
To launch a Symfony on AWS EC2 server on Cloudways, follow these steps:
Install Symfony 5.x On AWS EC2
Enter a valid email address to sign up at the Platform.
Note: You can also sign up using your LinkedIn, Google, or Github account.
Enter the details and click “START FREE” to initiate the process.
For this tutorial, I am going to install the latest version of the Symfony framework over the PHP application on AWS EC2.
Select PHP Application
Select Custom PHP Application from the drop-down menu and enter a name for the application, server, and select the project.
Choose the Cloud Infrastructure – AWS EC2
You can choose from the top five amazing cloud server providers. I am going to opt for AWS infrastructure
Configure Your Server
Select server size, bandwidth, and storage space.
Remember that your server should have enough storage, RAM, and bandwidth to take care of traffic spikes and for uncertain situations.
You can always scale server configuration through the Vertical Scaling function when your requirements increase.
Click LAUNCH SERVER and wait for a few minutes for the optimized PHP application to be deployed on the AWS Server.
Launch SSH Terminal
Move to the “Server Management” tab to launch the SSH Terminal. Here you can find the login credentials for the SSH terminal to access your server.
Install Symfony 5.x Using Composer
In the SSH Terminal, move to the public_html folder.
Note: As a precautionary measure, delete all the existing files and folders inside the public_html folder through the following command:
rm -Rf *
Now, use the following command to install Symfony 5.x
composer create-project symfony/website-skeleton my_project_name
Replace my_project_name with the desired project name. I am going to use myproject as the project name.
Ready to Go!
Once the installation finishes, go to “Access Detail” in the “Application Management” tab and visit the application’s URL
http://your_application_url/your_project_directory/web
This is it, the latest version of Symfony is ready to use.
Note: You no longer need to configure the database during the installation process. as required for the earlier versions.
Why Cloudways?
In addition to the user-friendly UI, the fully managed Platform offers several exciting features including a free SSL certificate by Let’s Encrypt, an optimized PHP stack, CloudwaysBot for prompt notifications, vertical scaling, and top notch technical support
To help you make an informed decision, Cloudways offers a free 3-day trial.
If you still have any confusion about installing Symfony on AWS, feel free to comment below and I’ll answer them for you.
Customer Review at
“Cloudways hosting has one of the best customer service and hosting speed”
Sanjit C [Website Developer]
Salman Siddique
Salman is a content marketer with a CS background, so he is (very) good at creating and marketing technical content. When not working as a Digital Content Producer at Cloudways, he enjoys reading interesting stuff and learning new skills.