When to move from shared hosting to a VPS
A VPS does not make a site faster by itself: it gives you resources and freedom, and with them the job of running a server. Here is how to tell that hosting has become too small, when the problem can be solved without moving, and how to migrate a site so visitors notice nothing.
A move from shared hosting to a VPS often starts with "the site is slow". Sometimes that really is the ceiling of a shared server, and sometimes it is a heavy plugin, unoptimized images or missing caching, which will be just as slow on a VPS. Before paying more and taking on server administration, find out what exactly the site is hitting. Below: the signs that justify a move, the cases where it will not help, an honest cost estimate and a step-by-step plan.
Signs that hosting has become too small
- The site hits account limits. Shared hosting limits CPU time, memory, concurrent processes and the number of files (inodes). When they are exceeded, the site returns 503 errors or 508 Resource Limit Is Reached, and the panel shows graphs pinned to the ceiling. If this happens on ordinary days, not only during spikes, the account does not have enough resources.
- You need software the host will not install. A Node.js or Python application that runs constantly, Redis, a search engine, job queues, non-standard PHP extensions, your own database version.
- You need background processes. Queue workers, websockets, bots, product imports more often than the host's cron allows, long scripts that the hosting kills on timeout.
- There are many projects. A dozen sites on one account share the same limits, and a problem with one slows the others. On a VPS you can split them into PHP pools with separate limits.
- You need control over the environment. Your own web server configuration, access to logs, custom firewall rules, isolation requirements from a client or an audit.
When moving will not help
If the site is slow under light load, the cause is usually the site itself. On a VPS with the same settings it will be just as slow, only more expensive.
- Pages take long to build because of dozens of plugins or a heavy theme: page caching and a plugin audit help.
- A page weighs several megabytes because of images: compression, modern formats and lazy loading help.
- Slow database queries: indexes and cleaning up tables help.
- The hosting server is far from the audience: changing the hosting location is enough, no VPS required.
An intermediate step is a higher hosting plan with larger limits. If the only problem is limits and you need no software beyond the standard set, this is cheaper and needs no administration. Plans for several sites are collected in hosting for 10 sites.
What a VPS really costs
Comparing the price of hosting with the price of a VPS directly is misleading: hosting already includes things you will have to pay for or do yourself on a VPS.
| Cost item | Shared hosting | VPS |
|---|---|---|
| Server | Included in the plan | Plan price, usually from 2 GB of memory for a CMS site |
| Control panel | Included | Free or paid licence, or no panel |
| Backups | Usually included | Often a separate service or your own setup |
| Domain email | Included | Your own mail server or a separate service |
| Updates and security | Done by the host | Done by you or an administrator |
The main hidden cost is time. System updates, monitoring, certificate renewals and fixing problems at night are now yours. If nobody can administer the server, look for managed plans from the host or budget for an administrator.
Which VPS to take for a site from shared hosting
Look at the usage graphs in the hosting panel for the last month: they show how much CPU and memory the site actually uses at peak.
- One or two sites on WordPress or another CMS: 2 vCPU, 2 GB of memory, 30–40 GB NVMe.
- A store with a catalogue of thousands of products or several busy sites: 2–4 vCPU, 4 GB of memory.
- Add a control panel to the estimate if you install one: it takes part of the memory and disk.
Ready-made selections: VPS for a website, VPS for WordPress and VPS for an online store. How to read the other plan parameters is covered in How to choose a VPS. For a first move, hourly billing is convenient: you can build the server, test the site and only then pay for a month.
What to do before the move
- Inventory. Write down the PHP version and enabled extensions, the database version, cron jobs, redirects and .htaccess rules, mailboxes and forwards, subdomains.
- Email. On shared hosting, email usually lives on the same account. A mail server of your own on a VPS needs PTR, SPF, DKIM and DMARC set up, and many hosts block outgoing port 25 by default. It is often easier to move the domain's email to a separate mail service before moving the site. If you do want mail on your own server, see VPS for a mail server.
- DNS TTL. A day or two before the switch, lower the TTL of the domain's A record to 300 seconds so the address change propagates quickly.
- A fresh backup of files and database on the hosting: your rollback point if something goes wrong.
A migration plan without downtime
- Prepare the VPS: update the system, create a user for SSH key login, enable the firewall, install the web server, the right PHP version and the database.
- Move the site files and the database dump, create a database user with the same privileges, move the cron jobs.
- Test the site on the new server without changing DNS: map the domain to the new IP in the hosts file on your computer and go through the main pages, forms and cart.
- Issue a TLS certificate on the new server. If HTTP domain validation is not possible before the DNS change, use DNS record validation.
- Put the site into read-only mode for the final sync (for a store, a few minutes without new orders) and move a fresh database dump.
- Change the A record to the new IP. Thanks to the short TTL, most visitors will reach the new server within half an hour.
- Keep the hosting for at least a week: watch the new server's logs and keep the old copy as a fallback.
After the move
Set up automatic security updates, a daily backup off the server, external uptime monitoring and log rotation. Check disk and network speed on the new server; the method is in How to test VPS ping and speed before you pay. If after a few months the server is constantly loaded to the limit, the next step may be a larger plan or a dedicated server. And if it turns out you do not need a VPS, you can move back to shared hosting the same way.