Skip to content
terminal
$ dnf install openlitespeed-litehttpd litehttpd
Installed: openlitespeed-litehttpd-1.8.5, litehttpd-2.0
$ systemctl restart lsws
$ curl -I localhost:8088/
HTTP/1.1 200 OK
x-custom-header: LiteHTTPD
cache-control: max-age=31536000
$ curl -sI localhost:8088/test-redirect/old-page
HTTP/1.1 301 Moved Permanently
location: /test-redirect/new-page
$ curl -sI localhost:8088/.htaccess
403 Forbidden # protected

Make OLS Understand .htaccess

The missing .htaccess engine for OpenLiteSpeed. 80 directives. 90%+ Apache compatible. 2x faster. Free and open source.

90%+ Compatible

80 directives: Require, Header, RewriteRule, ExpiresByType, FilesMatch, If/ElseIf/Else and more. WordPress plugins just work.

2x Faster

22,000+ RPS on static files. Only 0.7% overhead from 200-line .htaccess parsing vs Apache’s 4.2%.

30% Less Memory

676 MB baseline vs Apache’s 969 MB. Module adds only +13 MB over stock OLS.

5-Minute Setup

Copy .so, set allowOverride 255, restart. Your .htaccess files work unchanged.


Stock OpenLiteSpeed ignores most .htaccess directives — Require all denied returns 200, Header set is silently skipped, RewriteRule [R=301] returns 404. Security plugins like Wordfence and AIOS are effectively disabled.

LiteHTTPD comes in two editions:

  • LiteHTTPD-Thin — the .so module alone on stock OLS. Adds security headers, ACL, authentication, caching, conditionals, and redirects. Ideal for quick deployment.
  • LiteHTTPD-Full — module + patched OLS. Adds full RewriteRule execution, php_value/php_flag, and engine-level Options -Indexes. Required for complete Apache migration.

Security

Require all/ip/env, FilesMatch ACL, Options -Indexes, AuthType Basic, IPv6 CIDR access control, brute force protection.

URL Rewriting

RewriteEngine, RewriteCond, RewriteRule with [R=301,L,QSA,F,G] flags, RewriteBase, RewriteOptions, RewriteMap.

Response Headers

Header set/unset/append/merge/add/edit, env=VAR conditionals, Header always, RequestHeader.

Cache Control

ExpiresActive, ExpiresByType, ExpiresDefault with automatic Cache-Control and Expires header generation.

Conditionals

If/ElseIf/Else with ap_expr: ==, !=, =~, -f, -d, -ipmatch. Conditional headers, access control, type overrides.

PHP Config

php_value, php_flag, php_admin_value/flag passed to lsphp via LSIAPI.


Apache httpdStock OLSLiteHTTPDLSWS Enterprise
Static RPS11,08223,24222,10424,786
.htaccess overhead-4.2%-18.8%-0.7%-18.1%
Memory969 MB663 MB676 MB819 MB
Compatibility100%44%90%+100%
LicenseFreeFreeFreePaid
Security ACLFullMissingFullFull


Check software end-of-life dates at EOL.Wiki.

AI-native open source server control panel: WebCasa.

Lightweight web server with high Apache httpd compatibility: LiteHTTPD.