Install the OpenLiteSpeed Web Server on Ubuntu 20.04 quickly with full setup instructions, admin configuration, firewall rules, and default port changes. Our Live Support Team is always here to help you.
How To Install the OpenLiteSpeed Web Server on Ubuntu 20.04
When you want a fast and lightweight web server on your VPS or dedicated machine, OpenLiteSpeed is often the first choice. It’s known for its performance and flexibility, and setting it up on Ubuntu doesn’t take much time. Below, you’ll see exactly how to Install the OpenLiteSpeed Web Server on Ubuntu 20.04 with every command you need.

Installing OpenLiteSpeed
To begin, update the package manager cache:
sudo apt update<c/ode>
Next, install any pending upgrades:
sudo apt upgrade
Once that’s complete, enable the OpenLiteSpeed repository by fetching and adding the developer’s signing key:
sudo wget -O - https://rpms.litespeedtech.com/debian/enable_lst_debian_repo.sh | sudo bash
Now install OpenLiteSpeed along with the LiteSpeed PHP (LSPHP) interpreter:
sudo apt install openlitespeed lsphp81
This will set up the OpenLiteSpeed server package and LSAPI-integrated PHP 8.1.
Setting the Administrative Password
After installation, it’s time to secure the admin account. Run the following script:
sudo /usr/local/lsws/admin/misc/admpass.sh
You’ll be asked for a username. Press ENTER to keep admin as default or type your own. Then enter a password of your choice and confirm. Once done, you’ll see:
Administrator's username/password is updated successfully!
Connecting to the Server
By default, OpenLiteSpeed starts automatically. Confirm it with:
sudo systemctl status lsws
If it isn’t running, start it manually:
sudo systemctl start lsws
Next, open the required ports:
sudo ufw allow 8088,7080,443,80/tcp
Now head to your browser and visit:
http://server_domain_or_IP:8088
You should see the OpenLiteSpeed default page.
For the admin panel, open:
https://server_domain_or_IP:7080
Since it uses a self-signed SSL certificate, you may see a warning—proceed anyway. Enter the username and password you just created to access the dashboard.
Changing the Default Port
To make your site accessible on port 80 instead of 8088, log in to the admin panel. From the left menu, click Listeners. Then choose the magnifying glass icon (View) next to Default.
Click the edit icon on the Address Settings table, change the port from 8088 to 80, and save.
Finally, restart OpenLiteSpeed gracefully by clicking the restart arrow icon. Once confirmed, your site will now load without typing the port number.
Conclusion
That’s all you need to Install the OpenLiteSpeed Web Server on Ubuntu 20.04 and configure it for use. With just a few commands, admin setup, firewall adjustments, and port changes, your server is ready to host websites. You can now add your HTML, CSS, JS, or other files to:
/usr/local/lsws/Example/html
From this point on, your OpenLiteSpeed setup on Ubuntu 20.04 is secure, functional, and ready for production.
