Selected Flag
EN
Go to website

How can we help you?

Articles about: VPS

How do I install a Nginx webserver on my Linux VPS?


Here’s How to Install the Nginx Web Server on Your Linux VPS


1. Go to the VPS panel and log in.

2. Click Manage on your desired (Linux) server.



3. Ensure your VPS is running and click the VNC logo.



4. Log in.

Your username is likely "root," and your password can be found in your email.



5. Begin by updating everything. Type: sudo apt update



6. Ensure the firewall is enabled. Type: sudo ufw enable



7. Now start installing Nginx. Do this by typing: sudo apt install nginx



8. During the installation, you will be asked: "Do you want to continue?" Type Y and press the ENTER key.



9. During the installation, Nginx is automatically added to ufw. To list applications that work with ufw, type: sudo ufw app list



10. The output should look like this:



Nginx Full: All ports open (80 and 443).

Nginx HTTP: Only port 80 open.

Nginx HTTPS: Only port 443 open.


11. Now, open the firewall. It is recommended to only open the port you need. For us, this will be port 80. So we type: sudo ufw allow 'Nginx HTTP'



12. To check if this was successful, type: sudo ufw status



13. The output should look like this:



14. Nginx is now installed. You can confirm this by typing: systemctl status nginx. It should display active.




If you encounter any issues, feel free to reach out via Discord or create a support ticket through this link.