Development12 min read•Updated November 2026

VPS Hosting for Browser Automation

Quick answer

To run browser automation on a VPS, use Playwright, Puppeteer or Selenium with headless Chromium, Firefox or WebKit, installing the browsers' system dependencies and fonts (or using the official Docker images). Each browser instance uses significant memory, so run automation as queued jobs with a fixed concurrency, reuse a browser and open new contexts per task, set timeouts on every action, and always close pages and browsers, even on errors, to avoid leaked processes. In Docker, give enough shared memory. Respect the terms and rate limits of sites you automate, and monitor memory, job durations and failures.

Teams use browser automation for many legitimate tasks: generating PDFs and screenshots from HTML, end-to-end testing, monitoring that critical user journeys work, filling internal web forms that have no API, and archiving pages. Running these on a VPS gives a stable, always-on environment with predictable costs. Browsers are heavy programs, though, so a little engineering makes the difference between a reliable service and a server that runs out of memory.

Choosing a Tool

ToolLanguagesNotes
PlaywrightJavaScript/TypeScript, Python, Java, .NETChromium, Firefox and WebKit; auto-waiting; isolated browser contexts
PuppeteerJavaScript/TypeScriptChrome and Firefox; widely used for PDFs and screenshots
Selenium WebDriverMany languagesW3C WebDriver standard; works with Selenium Grid for distribution

For end-to-end testing, see our Playwright testing guide.

Server Setup

  • Install browsers through the tool (for example npx playwright install --with-deps chromium), which also installs required system libraries on supported distributions.
  • Install fonts, including fonts for Indian scripts (such as Noto fonts) and emoji, or text in screenshots and PDFs will render as boxes.
  • Run headless; for the rare case needing a headed browser, use a virtual display such as Xvfb.
  • Run automation as a dedicated non-root user.

Running in Docker

Official images (such as Playwright's) include browsers and dependencies at matching versions. Chromium uses /dev/shm for shared memory, and Docker's small default can cause crashes, so increase it with --shm-size or follow the tool's recommended settings. Keep the browser sandbox enabled by running as a non-root user where possible, and set memory limits on the container so a runaway browser cannot affect the rest of the server.

Memory and Concurrency

A headless browser commonly uses hundreds of megabytes, and heavy pages can use much more. Concurrency, not request rate, decides the server size.

  • Launch one browser per worker process and create a new context (an isolated, incognito-like session) per task, which is much cheaper than launching a browser each time.
  • Limit concurrent pages per worker, and limit worker count to what memory allows.
  • Restart browsers periodically (for example after a few hundred tasks) to release memory that builds up.
  • Block unnecessary resources (ads, large media) for tasks that do not need them.

Run Automation as Jobs

Do not launch browsers inside web requests. Put tasks on a queue and let workers with fixed concurrency process them, returning results through a callback or status endpoint (see our background workers guide). This protects the server from traffic spikes and makes retries and timeouts manageable. PDF generation pipelines are covered in our file processing guide.

Reliability

  • Set timeouts for navigation and each action, plus an overall job timeout.
  • Close pages, contexts and browsers in finally blocks so errors do not leak processes.
  • Run a periodic check for orphaned browser processes and kill them.
  • Prefer stable selectors (roles, labels, test IDs) over fragile CSS paths.
  • Save screenshots and traces on failure for debugging.
  • Retry transient failures with backoff, but not failures caused by changed pages.

Responsible Automation

Automate only sites and systems you are allowed to use this way. Read and follow terms of service and robots.txt where relevant, prefer official APIs when they exist, keep request rates low, identify your automation honestly where appropriate, and never use automation to bypass security controls, access accounts you are not authorised to use or collect personal data unlawfully. Under Indian data protection law and others, collecting personal data carries obligations.

Security

  • Keep browsers updated; they process untrusted content and receive frequent security fixes.
  • Do not render arbitrary user-supplied URLs without restrictions, since that can be used to reach internal services; block private IP ranges and metadata addresses.
  • Store credentials for automated logins in a secrets store, not in scripts.
  • Isolate automation from production databases and secrets.

Monitoring

Track queue depth, job duration percentiles, failure rate by task type, memory and CPU usage, and the number of running browser processes. A steady rise in browser processes signals a leak; rising durations often mean pages got heavier or concurrency is too high.

Sizing

WorkloadSuggested plan
Occasional screenshots, PDFs, a few monitoring journeys2 vCores / 8 GB
Steady PDF generation or several parallel sessions4 vCores / 16 GB
Large test suites or high-volume rendering8 vCores / 32 GB, or several worker servers

Measure memory per session with your real pages, then set concurrency so peak usage leaves headroom. CPU-heavy rendering benefits from more cores (see our heavy CPU workloads guide).

Example: Invoice PDFs and Journey Checks

A SaaS company runs Playwright workers on a 4 vCore / 16 GB VPS. One queue renders invoice PDFs from HTML templates with four concurrent contexts; another runs login and checkout journeys every ten minutes against their own app, alerting on failure with a screenshot. Browsers restart every 300 jobs, and a cron job kills any orphaned browser older than an hour.

Common Mistakes

  • Launching a new browser for every task.
  • Unlimited concurrency until memory runs out.
  • Missing fonts, producing broken PDFs.
  • Leaked browser processes after errors.
  • Automating sites in ways their terms do not allow.

In Short

Use Playwright, Puppeteer or Selenium on a properly prepared server, run automation as queued jobs with fixed concurrency, reuse browsers with fresh contexts, clean up every process, automate responsibly and monitor memory.

SkyRainCloud Plans for This Workload

Each headless browser needs memory and CPU. 2 vCores / 8 GB runs a few browsers at once; 4–8 vCores with 16–32 GB suits many parallel sessions for screenshots, PDFs or testing.

AMD EPYC 7C13 VPS

Dedicated KVM vCores on AMD EPYC 7C13 (up to 3.70 GHz) with DDR4 ECC memory, NVMe SSD and an unmetered 1 Gbps port.

PlanvCoresRAMStorageNetworkPriceGood forBuy
VPS 1 — AMD28 GB DDR4 ECC40 GB NVMe SSD1 Gbps, unmetered₹649/monthWebsites, small APIs, bots, staging and VPN serversOrder
VPS 2 — AMD416 GB DDR4 ECC80 GB NVMe SSD1 Gbps, unmetered₹1,299/monthWooCommerce, Node.js/Python backends, Docker Compose stacks, CI runnersOrder
VPS 3 — AMD832 GB DDR4 ECC150 GB NVMe SSD1 Gbps, unmetered₹2,499/monthProduction databases, high-traffic sites, multi-container appsOrder
VPS 4 — AMD1664 GB DDR4 ECC250 GB NVMe SSD1 Gbps, unmetered₹4,899/monthLarge production workloads, SaaS platforms, analytics, in-memory cachesOrder

Intel Xeon Platinum 8269CY VPS

KVM VPS on Intel Xeon Platinum 8269CY (up to 3.80 GHz Turbo) with DDR4 ECC memory, NVMe SSD, full root access and an unmetered 1 Gbps port.

PlanvCoresRAMStorageNetworkPriceGood forBuy
VPS 1 — Intel28 GB DDR4 ECC40 GB NVMe SSD1 Gbps, unmetered₹649/monthBusiness websites, small apps, scheduled jobs and botsOrder
VPS 2 — Intel416 GB DDR4 ECC80 GB NVMe SSD1 Gbps, unmetered₹1,169/monthBusiness software, mid-size databases, several sites on one serverCheck stock
VPS 3 — Intel832 GB DDR4 ECC150 GB NVMe SSD1 Gbps, unmetered₹2,249/monthERP/CRM stacks, heavier databases, multiple production appsCheck stock
VPS 4 — Intel1664 GB DDR4 ECC250 GB NVMe SSD1 Gbps, unmetered₹4,299/monthHigh-memory workloads and consolidated production serversCheck stock

Prices are monthly in INR as listed on the SkyRainCloud store (verified 2026-11-14). Stock and final pricing are shown on the product page at checkout.

Frequently Asked Questions

Can I run headless Chrome on a VPS?
Yes. Install it through Playwright or Puppeteer with its system dependencies, or use an official Docker image.
Playwright or Puppeteer?
Playwright supports several browsers and languages with isolated contexts; Puppeteer is JavaScript-focused and popular for PDFs and screenshots.
How much memory does a headless browser use?
Commonly hundreds of megabytes, more for heavy pages; measure with your real workload.
How many browsers can run at once?
As many as memory allows with headroom; set fixed concurrency based on measured usage.
Why does Chromium crash in Docker?
Often because of small shared memory; increase /dev/shm with --shm-size or follow the tool's recommended settings.
Why are characters missing in my screenshots?
Fonts are missing; install fonts for the scripts you need, such as Noto fonts for Indian languages.
How do I avoid leaked browser processes?
Close pages and browsers in finally blocks, restart browsers periodically and kill orphaned processes.
Should automation run in web requests?
No. Queue tasks and process them in workers with fixed concurrency.
Is web automation legal?
It depends on the site's terms, the data involved and local law; automate only what you are permitted to and prefer official APIs.
Which plan suits browser automation?
2 vCores / 8 GB for light use; 4 to 8 vCores with 16 to 32 GB for many parallel sessions.
Instant UPI • ₹649/mo
Fast KVM Cloud Provisioning