Cubs

Cubs vs Railway

Cubs vs Railway: ephemeral sandboxes or a machine you keep

Railway sells a deployment platform with sandboxes bolted on, and its documentation says plainly what those sandboxes are for: run something, then throw it away.

Published 4 Dec 2026Facts checked 4 Dec 2026

The short version

Railway's sandboxes are isolated Linux VMs you create programmatically, run commands in, and destroy, billed per second for CPU used, memory in use and egress. On the paid plans the idle timeout defaults to 30 minutes and can be disabled for an infinite TTL. Cubs is a persistent computer sized once, metered per second from prepaid credit, that costs little to keep paused and needs no keepalive to stay alive. Railway is the better deployment platform by a wide margin. Cubs is the better workstation for an agent that has to still be working when you check in tomorrow.

Facts about Railway checked on 4 Dec 2026. Their pages change; verify before you rely on a cell.
DimensionRailwayCubs
MachineAn isolated Linux VM in one of your Railway environments, sized in vCPU and memory at creation. The standard image is Ubuntu with git, Node and common coding agents preinstalled.One Linux computer sized 2 to 32 vCPU, with 2 GB RAM and 15 GB NVMe per vCPU, that is not part of a deploy.
Stays runningDestroyed on an idle timeout, 30 minutes by default on Hobby and Pro, 5 minutes on Free and Trial. The timeout can be set to zero for an infinite TTL on Hobby and Pro, and their docs warn a background process does not count as activity.Runs until you pause or delete it. There is no idle timer, no keepalive and no heartbeat to send. Pausing is a decision you make, and it keeps the disk.
Size and pricePer-second VM rates: $50 per vCPU per month for CPU actually used and $50 per GB per month for memory in use, plus $0.05 per GB egress. A 20-minute task at 1 GB and 30% of a core is about three cents.$6 per vCPU per month running, $2 paused, which works out at $0.0329/hour for a 4 vCPU machine. Sizes are 2 to 32 vCPU in whole steps.
BillingResource usage against a plan, with memory still billable while a VM waits for work. Plans start at $0, $5 and $20 a month, and the subscription fee counts toward usage.Prepaid credit metered per second and debited from the balance. $25 to start with no card, and the balance floors at zero rather than going into arrears.
Agents includedThe standard sandbox image preinstalls common coding agents, and there is a separate cloud agents product with terminal sessions and a dashboard.None bundled. Install the agent you already pay for, and copy the sign-ins from your machine instead of walking through each provider again.
Your own toolsYou build an image with templates: packages, environment and build steps, cached. It is the container mindset applied to a VM, and it is good at reproducibility.apt, your dotfiles, your editor over SSH, your private keys, installed once and kept. Changes survive a pause because the disk is not rebuilt.
Reaching itA TypeScript SDK, a CLI, an HTTP API, SSH from the dashboard, and public domains per forwarded port. Programmatic control is the primary interface.SSH with a key, plus terminals, previews and forwarded ports in a browser tab and on a phone.

When to choose Railway

  • Your product creates sandboxes on demand for other people's agents, where destroying one is the expected end of a request.
  • You are already deploying the service next to the sandbox and want it inside the same private network.
  • You want checkpoints and forks as first-class operations, so a fresh attempt starts from a configured state instead of a clean image.

When to choose Cubs

  • The agent should still be there tomorrow, with no keepalive job whose failure silently kills it.
  • The machine holds state worth keeping: a local database, a dev server, uncommitted work.
  • You want to prepay a balance and stop there, rather than watch a resource graph and a spending limit.

Railway is candid about what a sandbox is

The word at the top of their sandbox documentation is ephemeral, and the recommended loop is create, configure, checkpoint, fork, verify, destroy. That is a good design for the job it is aimed at: run a command against generated code, keep the result, bin the machine. Nothing accumulates, nothing needs patching, and the bill tracks the work.

Their own advice makes the intent unmistakable. To keep costs down they suggest destroying sandboxes when the work is done, keeping the idle timeout short, and preferring checkpoints over long-lived sandboxes for state you reuse. A product that tells you to checkpoint rather than persist has made a decision on your behalf, and for its intended users the decision is correct.

What the idle timeout really means

The default is 30 minutes on the paid plans and five on Free and Trial. The detail that catches people is in the middle of their documentation: a background process outside an active session does not keep a sandbox alive. Keeping one up means sending heartbeat() on an interval shorter than the timeout, and the docs suggest leaving room for a slow or failed request.

Set the timeout to zero and you have an infinite TTL, available on Hobby and Pro. So the capability to keep a machine exists, and claiming otherwise would be dishonest. The difference is that it is a configuration you have to discover, remember and defend, and the default behaviour of the platform is the opposite. An agent that ran a heartbeat from inside the sandbox would have to be written that way, and a tmux session with an idle terminal produces no traffic at all.

On Cubs there is no timer to configure and no heartbeat to send, because the primitive is a machine that exists until you say otherwise. That is a smaller claim than it sounds. It just means the product assumes persistence and the platform assumes destruction.

Billing shapes, compared honestly

Railway’s VM pricing is genuinely elegant: $50 per vCPU per month for CPU actually used, $50 per GB per month for memory in use, $0.05 per GB of egress. A sandbox that averages 30% of a core and one gigabyte costs a few cents for a twenty-minute run. For bursty work that is hard to beat, and their published arithmetic shows the working.

The catch is in the same paragraph. Memory remains billable while a VM waits for work, along with background CPU and any traffic. An agent waiting on a human, a model call or a queue still holds its memory, and memory at $50 per GB per month is not a rounding error across 730 hours. A machine that is mostly idle is exactly the case where per-second resource billing and per-vCPU pricing diverge, and they diverge in favour of a cheap paused rate.

That is the whole argument: $2 per vCPU per month is a price for existing without computing. Railway has no equivalent line item, because it does not keep the state to price. Its answer to a gap between sessions is a checkpoint and a destroy, which is cheaper than a paused machine for a month and more expensive in the five minutes after you resume, when you discover what the checkpoint did not capture.

The other half of Railway

It would be dishonest to compare only the sandbox. Railway’s real product is deployment: a repository becomes a service with a domain, logs, metrics, a private network and a set of environment variables, and that is genuinely better than anything a single rented machine does. If you are shipping the thing the agent is writing, you want this, and you probably want it in the same place the agent works.

Which is why the two products compose rather than compete. Put the agent on a computer with a disk it keeps. Deploy what it wrote to the platform that turns a repository into a URL. Paying for both is not duplication; it is paying each one for what it is good at, and the machine bill stays small because it is not carrying the deployment tooling.

The one question that decides it

Ask what happens when the agent goes quiet for an hour. On Railway, unless you changed a setting, the sandbox is destroyed, and whatever was only in memory is gone with it. On Cubs, nothing happens, because idle is the normal state of a machine whose human is asleep.

If your agents never go quiet for an hour, Railway’s defaults cost you nothing and its programmatic control is a real advantage. If they go quiet every time you close the laptop, then a platform whose default is destruction is a platform you will spend the year configuring around: a heartbeat here, a longer timeout there, and one 03:00 failure where the heartbeat did not fire.

There is also a version of this question about tools rather than time. Railway’s sandbox is built from an image, which is excellent when the environment is defined by the repository and awkward when the environment is a machine you have been accumulating for a year. A ~/.gitconfig, an SSH key, a Python toolchain installed by three different installers over eighteen months, a .envrc that only works because of one shell extension: none of that is in a Dockerfile, and all of it is on a disk you keep.

That is why the two products tend to end up side by side rather than in competition. The image holds what the repository needs. The machine holds what you need. A team that has both stops arguing about whether the sandbox should be more like a laptop, because it does not have to be.


Cubs is the workstation half: one computer, sized once, $6 per vCPU per month running, $2 paused, reachable over SSH. It has no deploy pipeline, no checkpoints and no fork. Use Railway for those.

Sources

Railway documentation, read on the date above. We are not affiliated with them and they have not reviewed this page.

Questions

Questions

Do Railway sandboxes stop on their own?
Yes, on an idle timeout. It is 30 minutes by default on the paid plans and 5 minutes on Free and Trial, and their docs warn that a background process does not keep a sandbox alive by itself. You can disable it on Hobby and Pro.
Is Railway cheaper than Cubs?
For short tasks, often. Their own worked example is about three cents for a 20-minute agent run. The comparison changes for a machine that idles most of the day, where memory in use stays billable while it waits for work.
Can I use my own editor with a Cubs machine?
Yes. SSH with a key means VS Code, Cursor, Zed or a plain terminal connect the way they connect to any other server.
Does Cubs deploy from a repository?
There is no build pipeline and no domain per service. You clone and build on the machine the way you would on a laptop, which is the point of renting a computer rather than a deploy target.

Read next

A computer that stays on

A machine that stays on, with your coding agents on it. $25 of credit to start, no card.

Get the download link

Enter your email and we will send the download link when the signed build ships. Open it on a Mac with Apple Silicon.

One message when the build is signed. No newsletter.