Nginx is a free and open source web server, reverse proxy server, a mail proxy server and a generic TCP/UDP proxy server. It is released under under the 2-clause BSD-like license.
Install Nginx Server on Ubuntu
Open the terminal application (ctrl+alt+t) and run below command.
sudo apt install nginx -y
After nginx installation, start and enable it using below commands.
Start nginx on Ubuntu:
sudo systemctl start nginx
Enable nginx on Ubuntu:
sudo systemctl enable nginx
After above commands you can check the status of the nginx server using below command in the terminal.
sudo systemctl status nginx
and check the installed Nginx version using below command.
nginx -V
Now open the browser and go to the below url. Here we are installing nginx locally.
http://localhost
If you see below page, then the nginx web server is successfully installed and working.
You can disable and stop nginx using below commands.
sudo systemctl disable nginx
sudo systemctl stop nginx