OpenLiteSpeed Documentation
A comprehensive guide to installing, configuring, and operating OpenLiteSpeed — a high-performance, event-driven web server built for speed, low resource usage, and modern web workloads.
This documentation is written for administrators who work in tmux, navigate with yazi, and build automation with bash. Every task is covered via the command line. You do not need the WebAdmin GUI for day-to-day operations. OpenAI-powered tools like opencode can be piped directly with log output and config files for AI-assisted debugging.
Learning Path
1. Foundations
Start here to understand the server model, filesystem layout, and admin workflow.
- Core Foundations — Server basics, installation, directory layout, and CLI management
- Server Configuration — Listeners, virtual hosts, server settings, and config files
2. Core Workflows
Master the layers that make OpenLiteSpeed fast and efficient.
| Layer | Module | Focus |
|---|---|---|
| Tune | Performance Optimization | Caching, compression, static delivery, and connection tuning |
| Execute | PHP Integration | LSAPI, external apps, handlers, and PHP tuning |
| Protect | Security | TLS, access control, ModSecurity, and DDoS protections |
| Observe | Logging and Monitoring | Logs, statistics, and operational metrics |
3. Edge & CDN Integration
Connect OpenLiteSpeed to Cloudflare for caching, security, and global delivery.
- Cloudflare Integration — DNS, proxy behavior, real IP handling, and edge security
- Cloudflare SSL Full (Strict) Setup — Origin certificates, listener SSL, dashboard settings, and verification
4. Advanced & Reference
Expert-level routing, containerization, automation, and troubleshooting.
- Advanced Features — Rewrite engine, reverse proxy, containers, CLI management, and bash automation
- Troubleshooting and Maintenance — Reloads, diagnostics, SSL failures, and upgrades
5. Cheatsheets
Quick-reference cards for every OLS operation — designed for fast lookup in a tmux session.
| Cheatsheet | What It Covers |
|---|---|
| CLI Quick Reference | All CLI commands — service, logs, PHP, diagnostics |
| Config File Syntax | httpd_config.conf and vhconf.conf directives |
| Virtual Host Setup | Complete vhost workflow CLI to live site |
| PHP & lsphp Tuning | OPcache, process limits, extensions, overrides |
| Security Hardening | SSL, headers, IP rules, ModSecurity |
| Performance Tuning | HTTP/2, compression, caching, benchmarking |
| Troubleshooting Matrix | Errors → root cause → exact fix |
| Automation & Bash Scripts | Production scripts, cron, opencode workflows |
OpenLiteSpeed at a Glance
Request Flow: What Happens When a Browser Hits Your Server
Tooling Matrix
| Tool | Role | Best For |
|---|---|---|
| OpenLiteSpeed | Web server | Self-managed VPS, PHP hosting, WordPress |
| LiteSpeed Enterprise | Web server (commercial) | Shared hosting, enterprise support, advanced features |
| Nginx | Web server / reverse proxy | Static serving, upstream proxying, microservices |
| Apache | Web server | Legacy applications, .htaccess-heavy stacks |
| Cloudflare | CDN / Edge proxy | Edge caching, DDoS, WAF, DNS management |
Quick Start
# 1) Add the LiteSpeed repository
wget -O - https://repo.litespeed.sh | sudo bash
# 2) Install OpenLiteSpeed and PHP
sudo apt update
sudo apt install openlitespeed lsphp84 lsphp84-common lsphp84-mysql
# 3) Set the admin password
sudo /usr/local/lsws/admin/misc/admpass.sh
# 4) Start the service
sudo systemctl start lsws
# 5) Verify — open in your browser
# Default site: http://your-server-ip:8088
# WebAdmin panel: https://your-server-ip:7080
- Basic Linux administration (SSH, file permissions, package management)
- Comfort with DNS, ports, and TLS terminology
- Familiarity with PHP hosting helps but is not required
Success Criteria
By the end of this documentation, you will be able to:
- Install and operate OpenLiteSpeed on Linux.
- Build clean listener and virtual host layouts.
- Tune caching, compression, and HTTP protocol settings.
- Run PHP efficiently with
lsphpthrough LSAPI. - Secure deployments with TLS, ModSecurity, and Cloudflare.
- Set up Cloudflare SSL Full (Strict) with origin certificates.
- Diagnose common server, permission, and SSL issues.