What is PHP hosting?
PHP hosting is web hosting that can run PHP, the language behind WordPress, Laravel, Drupal and a large share of the web. In practice that describes most shared, VPS and managed plans, because PHP support is standard. The questions that matter are which PHP version the host offers, which extensions are installed, and how much you can change.
For a small brochure site or a WordPress blog, almost any shared host will do. For a custom application, the details below decide whether a plan is a good fit.
What does Laravel need from a host?
Laravel is a PHP framework with more moving parts than a simple site. Before you buy a plan, check each item against the version of Laravel you use, since requirements change between releases. The official Laravel documentation lists the current minimum PHP version and extensions.
- A supported PHP versionMatch the minimum for your Laravel release, and make sure the host updates PHP regularly.
- Composer and SSHYou install dependencies with Composer. Without SSH you must upload the vendor folder yourself.
- PHP extensionsCommon ones include mbstring, openssl, pdo with your database driver, tokenizer, xml, ctype, json and fileinfo.
- Web root on public/Laravel should serve from its public folder. If you cannot change the document root, you need a workaround.
- Cron and queue workersScheduled tasks need a cron job every minute, and queues need a process that stays running.
- Safe environment settingsKeep the .env file outside the public web root and out of version control.
Which hosting type fits PHP and Laravel?
| Type | Simple PHP site | Laravel app | Queues and cron | Effort |
|---|---|---|---|---|
| Shared hosting | ||||
| Managed hosting | ||||
| VPS | ||||
| Cloud platform |
Editorial ratings from 1 (weak) to 5 (strong). They describe the hosting type in general, not a specific provider.
Shared hosting
- Setup
- Control panel, often cPanel. Quick to start.
- Laravel fit
- Works for small apps if SSH and Composer are available.
- Cost
- Lowest, but renewal prices rise.
VPS
- Setup
- You install and secure the stack yourself.
- Laravel fit
- Full control over PHP, queues and workers.
- Cost
- A few dollars a month and up.
How do you deploy Laravel on shared hosting?
If your plan has SSH, deployment is close to a normal server setup. If it does not, you have to build locally and upload the result, which is slower and easier to get wrong.
- Check the PHP version
Select the version your Laravel release needs in the control panel.
- Upload the project
Put the app above the public web folder, not inside it.
- Point the web root
Set the document root to the public folder, or copy its contents with the paths adjusted.
- Install dependencies
Run Composer over SSH, or upload the vendor folder built locally.
- Set the environment
Create .env with your keys and set the debug option off.
- Add the cron job
Run the Laravel scheduler every minute if you use scheduled tasks.
When is a VPS the better choice?
Choose a VPS when your app uses queue workers, long-running processes, a Redis cache or custom services, or when you need to control PHP settings and extensions. You trade convenience for control: you install the web server, PHP and a database, keep them updated and take your own backups. Our cheap VPS list shows the lowest entry prices and what we found using several of them.
If you would rather not manage a server, a managed PHP host or an application platform handles more of the work for a higher price.
What should you check before you buy?
- The PHP versions offered, and how quickly new ones arrive.
- SSH access and whether Composer is installed.
- Whether you can change the document root.
- Cron job and process limits, and whether workers can stay running.
- Memory and execution time limits, which affect long tasks.
- Backups, and whether the database is included in them.
Hosting that fits a simple PHP site is easy to find. Hosting that fits a growing Laravel app takes a few more checks, and it is worth doing them before you move.