Buyer's guide

Choosing a VPS for Claude Code, Codex and other coding agents

Coding agents don't need a powerful server. They need enough RAM for your project's toolchain, a region you're allowed to use, and a provider that will actually sell you the box. Here's how to size one, with prices we checked on the providers' own pages.

Choosing a VPS for Claude Code, Codex and other coding agents

Quick answer

Get 4 GB of RAM (Anthropic's stated minimum for Claude Code), 2 vCPUs and 40 GB or more of disk, in a region near you. You don't need a GPU, because the model runs at Anthropic, OpenAI or Google, not on your server. When we checked on 2026-10-01, the cheapest 4 GB plan we could actually order was OVHcloud's VPS-1, from €3.81 a month before VAT. Hetzner's 4 GB plans (€5.49–5.99) showed as unavailable, and Contabo's Cloud VPS 4 has 8 GB for €4.40 a month on a 24-month term. Mainstream US clouds charge $20–24 for 4 GB. A spare Mac mini or Raspberry Pi 5 at home costs nothing extra.

Most "best VPS for Claude Code" lists are affiliate pages ranked by commission. This one has no affiliate links, and it starts from what an agent actually does on the machine. The agent sends your prompt to a model hosted by its vendor, gets back text and tool calls, and runs those tool calls locally: reading files, running git, installing packages, building, testing. So the server's job is to run your project's toolchain. Size it for that.

What agents actually need

  • RAM: 4 GB is the sensible floor. Anthropic's system requirements list 4 GB+ RAM for Claude Code. Codex and Antigravity's agy are compiled binaries and lighter on their own. But an agent running npm install, a TypeScript build and a test suite goes well past 2 GB, and when Linux runs out of memory it kills processes. 2 GB can work for one agent on a small repo if you add swap. 8 GB is right if you run several sessions in parallel, or a database or Docker next to them.
  • CPU: 2 vCPUs is plenty to start. Agents mostly wait on the network. CPU matters while builds and tests run, so heavy compile jobs (Rust, large C++ or monorepo builds) benefit from 4.
  • Disk: 40 GB or more. node_modules, language toolchains, Docker images and several git worktrees fill 20 GB faster than you'd expect.
  • GPU: no. None of these CLIs run the model locally. Paying for a GPU instance buys you nothing here.
  • A supported region. Claude Code's requirements say it must be used from an Anthropic-supported country. Where the server sits counts, not just where you are.

If you go with 2 GB, add a swap file. It turns a crash into a slowdown:

sudo fallocate -l 2G /swapfile
sudo chmod 600 /swapfile
sudo mkswap /swapfile
sudo swapon /swapfile
echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab

Price table

Prices checked 2026-10-01

Every price below comes from the provider's own pricing page or official pricing API on that date, in the currency shown. Hosting prices change often, and Hetzner raised its prices in June 2026, so check the linked page before you buy. We have no affiliate relationship with any provider listed.

Provider & planvCPU / RAM / diskArchMonthly priceNotes
OVHcloud VPS-12 / 4 GB / 40 GBx86from €3.81 ex. VAT"From" price; we couldn't confirm the commitment term it assumes
OVHcloud VPS-24 / 8 GB / 75 GBx86from €7.21 ex. VATIPv4 included
Contabo Cloud VPS 44 / 8 GB / 100 GBx86€4.40 ex. VATEffective rate on a 24-month term; shorter terms cost more
Hetzner CX232 / 4 GB / 40 GBx86€5.49 ex. VAT+€0.50 for IPv4; showed as unavailable when we checked
Hetzner CAX112 / 4 GB / 40 GBARM€5.99 ex. VAT+€0.50 for IPv4; showed as unavailable when we checked
Hetzner CX33 / CAX214 / 8 GB / 80 GBx86 / ARM€8.49 / €10.49 ex. VATSame availability caveat
DigitalOcean Basic2 / 4 GB / 80 GBx86$248 GB / 4 vCPU: $48; 2 GB: $12
Vultr Regular Cloud Compute2 / 4 GB / 80 GBx86$208 GB: $40; 2 GB: $10 (from Vultr's public plans API)
Akamai (Linode) Shared2 / 4 GB / 80 GBx86$248 GB: $48; 2 GB: $12
AWS Lightsail2 / 4 GB / 80 GBx86$24 ($20 IPv6-only)8 GB: $44; static IP included
Scaleway DEV1-M3 / 4 GB / storage extrax86≈ €14.74 ex. VATHourly billing; block storage and IPv4 billed separately
Oracle Cloud Always Free A1up to 4 OCPU / 24 GB totalARM$0Idle instances can be reclaimed; capacity is often unavailable

What we couldn't confirm:

  • Hetzner. Its product pages load prices with JavaScript, so the figures above come from Hetzner's own price-adjustment notice, effective 15 June 2026. The Cost-Optimized line (CX and CAX) showed "currently unavailable" when we checked. Third-party trackers say stock comes and goes, but we didn't verify that.
  • Vultr. The marketing pricing page blocked our fetcher, so Vultr's prices come from its official public plans API.
  • OVHcloud. We couldn't find the terms behind its "from" prices.
  • Contabo. We couldn't confirm what Contabo charges on a one-month term (the €4.40 above assumes 24 months), or its setup fees.
  • Tax. The US providers' pages don't say how VAT is handled. Expect it to be added where it applies.

So which one?

  • Cheapest workable box in Europe: OVHcloud VPS-1 or Hetzner CX23/CAX11 if you can get one. Contabo has the most RAM per euro, provided you're happy with a long term.
  • A big US cloud: Vultr's $20 4 GB plan is the cheapest of the big four we checked. DigitalOcean, Akamai and Lightsail sit at $24.
  • $0, with patience: Oracle's Always Free ARM shape is generous on paper. Getting capacity, and keeping the instance from being reclaimed as idle, is the hard part.

Region and latency

Two latencies matter, and only one is worth optimising. Between you and the server: if you type into a terminal over SSH, every keystroke makes a round trip. 30 ms feels local and 150 ms feels sticky. mosh hides much of that. Between the server and the model API: an agent turn takes seconds to minutes, so an extra 80 ms per request from a European box to a US endpoint doesn't matter much. Pick the region closest to you, within a country your agent's vendor supports, and consider where your code is allowed to live if you have data-residency rules.

ARM vs x86

ARM servers (Hetzner CAX, Oracle A1, AWS Graviton) are often cheaper per GB of RAM, and the agents themselves are fine on them. Claude Code ships linux-arm64 builds, OpenAI publishes arm64 Linux binaries for Codex, and agy's installer has arm64 Linux builds. What can fail is your project: some npm packages with native modules, older Python wheels, and Docker images published only for amd64. If your stack is mainstream Node, Python, Go or Rust, ARM is a good deal. If you depend on an x86-only image or binary, pay the small premium for x86.

Home hardware

The cheapest server is one you already own:

  • Mac mini or an old laptop. Plenty of RAM, fast disk, and macOS or Linux both work. Turn off sleep (on macOS, sudo pmset -a sleep 0, or set Energy settings to prevent automatic sleep), plug it into ethernet, and you have a 24/7 box for the cost of electricity.
  • Raspberry Pi 5. It works on the 4 GB or 8 GB models with a 64-bit OS and an SSD rather than an SD card. Expect builds to be noticeably slower than on a VPS.
  • Reaching it. A home machine sits behind your router's NAT. Tailscale gives your phone a direct path to it without opening ports.

The trade-off is that a home machine shares your network and often your accounts. Give the agent its own user, keep personal SSH keys and browser profiles off that account, and read running agents with full permissions, safely before you relax permission prompts.

Set it up and run it from your phone

Once you have a box, the setup guides take it from there: Claude Code on a VPS, Codex CLI on a VPS and Antigravity CLI on a server. If you'd rather not do the install by hand, Maude works with any of the machines above: Linux or macOS, x86-64 or ARM, reachable over SSH. You add the server from the app, and it deploys its own daemon and installs Claude Code, Codex or the other agents at tested versions. The server connects out to Maude's relay, so a Mac mini behind home NAT works without opening a port. You still need each agent's own subscription or API key. The app is $2.99 a week after a 3-day trial, or $59.99 a year after a 7-day trial.

Frequently asked questions

How much RAM does Claude Code need?
Anthropic lists 4 GB+ RAM in Claude Code's system requirements. The CLI itself is not the heavy part — your project's installs, builds and tests are. 4 GB is a comfortable floor for one developer; 8 GB if you run several sessions or Docker alongside.
Is a $5 VPS enough?
At European providers, often yes: when we checked on 2026-10-01, OVHcloud's 4 GB VPS-1 started at €3.81 a month before VAT, Contabo's 8 GB plan worked out at €4.40 a month on a 24-month term, and Hetzner's 4 GB plans (€5.49–5.99) showed as unavailable. At the big US clouds we checked, the 4 GB plans were $20–24; their cheapest plans have less RAM than a coding agent plus a build wants.
Do I need a GPU to run Claude Code or Codex?
No. The models run at Anthropic, OpenAI or Google. Your server only runs the CLI and your project's tools, so a normal CPU instance is the right choice.
Can I use a Raspberry Pi?
Yes, a Raspberry Pi 5 with 4 or 8 GB and a 64-bit OS can run Claude Code, Codex and agy, all of which ship arm64 Linux builds. Use an SSD rather than an SD card, and expect slower builds than on a VPS.
ARM or x86 for a coding-agent VPS?
ARM is usually cheaper per GB and the agents run fine on it. Choose x86 if your project depends on Docker images or native binaries that are only published for amd64.

What changed

  • — First published. Prices checked on official provider pages (Vultr via its public plans API) on this date.

Got a box?

Point Maude at it and run Claude Code, Codex and more from your phone. iOS and Android.

Download Maude on the App Store Get Maude on Google Play