Articles on: 🌍 Web Hosting
This article is also available in:

How do I deploy a Laravel or Symfony site?

On your hosting, you need to place your files in the public_html directory, but this causes a problem with frameworks like Symfony or Laravel, which require their files to be placed in a public directory.


There's a simple method for using Symfony or Laravel with your hosting:


  • Log in via SSH or go to the Terminal in cPanel
  • Check that you're in the root of your hosting:

cd ~

  • Rename the public_html directory with the following command:

mv public_html public_html_bak

  • Create a symlink between your public directory and public_html with the following command (adjust /home/monuser/monappli/public to match your setup):

ln -s /home/monuser/monappli/public public_html

ea-php82 /usr/local/bin/composer install
You can also create an alias in your shell if you'd like to call composer with just the composer command.
Tip: if you're on a plan where SSH access isn't included, our technical support will do this for you. Just let us know the path to your public directory.

Updated on: 17/07/2026

Was this article helpful?

Share your feedback

Cancel

Thank you!