System Requirements
Database Requirements
- MySQL 5.7+ (or MariaDB 10.3+) is required
- The DB user needs to have a full privilege to manage the database, including privilege to
FLUSH TABLES, etc. - To ensure proper support for certain language characters, the database collation should be set to one of the following options, in order of preference, with the respective charset:
utf8mb4_0900_ai_ci,utf8mb4_unicode_ci,utf8mb4_general_ci,utf8mb3_unicode_ci,utf8mb3_general_ci,utf8_unicode_ci, orutf8_general_ci. - For optimal database performance, set
max_user_connectionsbetween30-100to control individual user load andmax_connectionsbetween150-200to handle overall traffic.
Server Requirements
- PHP 8.2 or greater (with all default PHP functions enabled, including
exec(),escapeshellarg(), etc.) - BCMath PHP Extension
- Ctype PHP Extension
- cURL PHP Extension (version 7.34.0 or greater)
- DOM PHP Extension
- Fileinfo PHP extension
- Filter PHP Extension
- Hash PHP Extension
- JSON PHP Extension
- Mbstring PHP Extension
- OpenSSL PHP Extension
- PCRE PHP Extension
- PDO PHP Extension
- Session PHP Extension
- Tokenizer PHP Extension
- XML PHP Extension
- GD PHP Extension (or Imagick PHP Extension)
- PHP Zip Archive
- Rewrite Module Enabled
PHP.ini Requirements
open_basedirmust be disabled
File and Folder Permissions
/bootstrap 775 /storage 775 (recursively)
Supported Web Servers
- Apache. Note: Fully supported.
- Nginx. Note: Fully supported.
- LiteSpeed (or OpenLiteSpeed). Note: Permissions and firewall management need to be properly handled. LSCache is not supported.
- Varnish. Important: The server cache management need to be properly handled. Strong server configuration and programming knowledge are required.
Server Resources Recommendations
The server resource capacity required for a Laravel application can vary significantly depending on the application's complexity, traffic, and the services it relies on. However, here are some general recommendations based on common use cases:
1. Small Laravel Application
- CPU: 1-2 vCPUs
- Server RAM: 2-4 GB
- RAM Allocated to PHP: 512 MB - 1 GB
- RAM Allocated to Database Server: 512 MB - 1 GB
- Hard Disk Space: 20-50 GB SSD
Suitable for small applications with low traffic, such as blogs, simple web pages, or small internal tools.
2. Medium Laravel Application
- CPU: 2-4 vCPUs
- Server RAM: 4-8 GB
- RAM Allocated to PHP: 1-2 GB
- RAM Allocated to Database Server: 1-2 GB
- Hard Disk Space: 50-100 GB SSD
Suitable for medium-sized applications, such as e-commerce sites, CMS, or applications with moderate traffic and a moderate number of users.
3. Large Laravel Application
- CPU: 4-8 vCPUs
- Server RAM: 8-16 GB
- RAM Allocated to PHP: 2-4 GB
- RAM Allocated to Database Server: 2-4 GB
- Hard Disk Space: 100-200 GB SSD (or more depending on storage needs)
Suitable for large applications with high traffic, extensive user base, or complex functionalities, such as social networks, SaaS platforms, or large e-commerce sites.
4. Enterprise-Level Laravel Application
- CPU: 8+ vCPUs
- Server RAM: 16-32+ GB
- RAM Allocated to PHP: 4-8+ GB
- RAM Allocated to Database Server: 4-8+ GB
- Hard Disk Space: 200 GB - 1 TB SSD (or more depending on storage needs)
Suitable for enterprise-level applications with very high traffic, mission-critical operations, or large databases requiring high performance and availability.
For most applications, starting with a medium-sized setup and scaling up as needed is a practical approach.
For example, all demo websites are hosted on shared hosting with the following characteristics:
- CPU: 4 vCore
- Server RAM: 8 GB
- RAM Allocated to PHP: Unknown
- RAM Allocated to Database Server: 512 MB
- Hard Disk Space: 500 GB NAS SSD
- Bandwidth: shared
- Concurrent Database Connections: 200
- Concurrent Database User Connections: 30 & 50