LiteSpeed Timeouts Explained (Firstserv Guide)
What is LiteSpeed?
All Firstserv hosting servers use LiteSpeed Web Server, a high-performance alternative to Apache. It’s designed to deliver faster page loads, improved efficiency, and better scalability for websites.
Why Do Timeouts Occur?
LiteSpeed includes a connection timeout limit to prevent long-running or stalled processes from affecting server performance.
This helps to:
- Prevent scripts from running indefinitely
- Avoid excessive resource usage
- Stop processes from stacking up and hitting account limits
When Might You Need to Disable It?
In some cases, you may encounter timeouts when:
- Running long scripts or background tasks
- Debugging or fixing code issues
- Using applications that require extended execution time
How to Disable LiteSpeed Connection Timeouts
⚠️ Only disable timeouts temporarily if required, as it can increase server resource usage.
Step 1: Locate Your .htaccess File
- Log in to cPanel → File Manager
- Navigate to your website directory (usually
/public_html) - Locate or create a file named
.htaccess
Step 2: Add the Following Code
Insert this into your .htaccess file:
Step 3: Apply Changes
- Save the file
- Allow up to 5 minutes for changes to take effect
What This Does
- Disables LiteSpeed connection timeouts
- Allows long-running processes to continue without interruption
- Leaves PHP timeout limits (if configured) still in effect
Important Notes
- ⚠️ This setting applies to the entire directory (e.g.
/public_html) - Any additional domains or subdirectories under this path will also be affected
- Extended runtime scripts may increase resource usage
Best Practices
- Only disable timeouts when necessary
- Re-enable default behaviour once testing or troubleshooting is complete
- Optimise scripts to avoid long execution times where possible
Summary
LiteSpeed timeouts are in place to:
- Protect server performance
- Prevent excessive resource usage
You can temporarily disable them via .htaccess, but should do so carefully and only when required.
If you need help editing your .htaccess file or troubleshooting timeout-related issues, the Firstserv support team is always available to assist.
