- Automation
- Linux VPS
- Ubuntu 24.04
Selenium and Playwright on a VPS
Selenium and Playwright run well on a GhostRDP Linux VPS Standard plan with 4 vCPU and 8 GB RAM in Germany or the Netherlands, from €12.99/mo.
Headless browsers need a few system libraries that a fresh server doesn't have. Playwright installs them for you, and Selenium can use the same libraries. This guide sets up both in one Python environment.
Headless Chromium
Playwright installs the browser and its system libraries.
Browsers in parallel
Memory for several headless browsers at once.
Scheduled jobs
Run scrapers on a timer with cron or systemd.
Plans for Selenium and Playwright
Each headless browser uses a few hundred MB of memory and a share of a core. Standard runs several browsers in parallel; Basic is fine for one or two.
Linux VPS Standard
€12.99/mo
€11.04/mo billed yearly, save €23/year
- 4 vCPU
- 8 GB ECC RAM
- 70 GB NVMe
- 1 Gbps port
Linux VPS Pro
€25.99/mo
€22.09/mo billed yearly, save €46/year
- 6 vCPU
- 12 GB ECC RAM
- 90 GB NVMe
- 1 Gbps port
Linux VPS Advanced
€34.99/mo
€29.74/mo billed yearly, save €62/year
- 12 vCPU
- 24 GB ECC RAM
- 150 GB NVMe
- 1 Gbps port
What you need
- Operating systemLinux VPS with Ubuntu 24.04 (Playwright supports Ubuntu 22.04 and 24.04)
- Minimum resources2 vCPU and 2 GB RAM for one or two browsers
- DiskAbout 1 GB for the browser downloads
Official site: playwright.dev
How to install Selenium and Playwright
Written for Ubuntu 24.04 from the official instructions. Run the commands as root and replace YOUR_SERVER_IP with your server's address.
- 1
Connect to your server over SSH
Use the IP address and root password from your welcome email (the server page has a Copy SSH command button). Windows 10 and 11, macOS and Linux all include an SSH client in the terminal.
Shell ssh root@YOUR_SERVER_IP - 2
Update the system
Install the latest security updates before you add anything else.
Shell apt update && apt -y upgrade - 3
Create a Python environment
One virtual environment in /opt/scraper for both libraries.
Shell apt install -y python3-venv python3 -m venv /opt/scraper /opt/scraper/bin/pip install playwright selenium - 4
Install Chromium and its system libraries
Playwright downloads its Chromium build and installs the Linux packages browsers need.
Shell /opt/scraper/bin/playwright install --with-deps chromium - 5
Test Playwright
Opens a page in headless Chromium and prints its title.
Shell /opt/scraper/bin/python - <<'EOF' from playwright.sync_api import sync_playwright with sync_playwright() as p: browser = p.chromium.launch() page = browser.new_page() page.goto("https://example.com") print(page.title()) browser.close() EOF - 6
Test Selenium
Selenium 4.6 and later downloads a matching Chrome and driver by itself (Selenium Manager) on first run.
Shell /opt/scraper/bin/python - <<'EOF' from selenium import webdriver options = webdriver.ChromeOptions() options.add_argument("--headless=new") options.add_argument("--no-sandbox") driver = webdriver.Chrome(options=options) driver.get("https://example.com") print(driver.title) driver.quit() EOF
After installing
- SchedulingRun jobs on a timer with cron (crontab -e) or a systemd timer, and log output to a file.
- Be a good citizenRespect each site's terms and robots.txt and keep request rates reasonable.
- ProxiesEach server has one IPv4 address. If you need more, add extra IPv4 addresses at checkout or use your own proxies.
Selenium and Playwright questions
Which plan do I need for scraping?
Standard for several browsers in parallel. Basic is enough for one or two at a time. Memory is usually the limit: plan on a few hundred MB per open browser.
Do I need a desktop to run the browsers?
No. Both run headless on a plain Linux server. If you prefer a visible browser, use a Windows RDP plan.
Should I use Playwright or Selenium?
Both work. Playwright installs its own browsers and waits for pages automatically; Selenium fits existing Selenium code and grids.
Can I add more IP addresses?
Yes, extra IPv4 addresses are an add-on at checkout.
Related apps
Docker
Docker Engine and Compose on a fresh Linux server
DevelopmentFrom €5.99/mo
Python trading bot
Run a Python bot (ccxt, broker APIs) as a 24/7 service
AutomationFrom €5.99/mo
Antidetect browsers
AdsPower, Multilogin, Octo and others on a Windows server
Networking and privacyFrom €14.99/mo
More on GhostRDP
Run Selenium and Playwright on your own server.
Online in minutes. Pay with crypto, no ID needed.