Report this

What is the reason for this report?

How do you deploy multiple websites on the same Ubuntu droplet

Posted on February 10, 2025

I have an existing website on my droplet. Since it is lightly loaded I want to deploy another website on this same droplet. I am looking for an app note or instructions.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Hi there 👋

You can definitely host multiple websites on the same Ubuntu droplet using either Nginx server blocks or Apache virtual hosts, depending on which web server you’re using.

Here are some tutorials that walk you through the setup:

If you’re using Docker, this video might help: YouTube: Hosting Multiple Websites with Docker.

Let me know if you have any questions!

- Bobby

Heya @a96586b9b23547c29c6be618017cd9,

Apart from what has been said, you can deploy it using docker and a docker container for easier management in the future. You can use Docker Compose or individual Docker containers with an Nginx reverse proxy to manage multiple sites efficiently.

Having said that, this is a bit more complex that the standart setup of installing either Apache or Nginx and configuring it server your files.

Heya, @a96586b9b23547c29c6be618017cd9

Depending on your current setup, if you use web-server as Apache or Nginx you can create another virtual host for the new site/domain and spin up the site in the corresponding root directory.

If you share more details about the setup we can give you the exact steps on how to setup this.

Regards

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.