I moved my AI agent to a $7/mo VPS. It fixed the worst parts of local dev.
I used to fire up my terminal, pull up my AI coding agent, and start a chunky refactor. That worked right up until my laptop hit 8% battery and suspended itself in the middle of a multi-file change. The agent was gone, state was gone, and I got to start over.
That pattern repeated enough times to get annoying. Battery anxiety, CPU throttling, and the absolute certainty that closing my lid meant killing whatever the agent was doing. I kept thinking: why is the most fragile part of my AI workflow the machine I carry around?
The cost of local-only AI coding
Running an AI coding agent on your laptop ties its uptime to your laptop's whims. Sleep mode and lid-close actions nuke the process. Thermal throttling kicks in once the fans spin up, so the agent gets slower the longer you run it. On battery, the OS starts clamping background services aggressively, often killing or suspending terminal sessions.
I'd set the agent on a task, walk away, and come back to a dead tmux pane and zero output. Sometimes I wouldn't even know if it had finished 30 files before the OOM killer showed up. That's not development. That's babysitting your hardware.
And it doesn't scale. I started treating my AI agent like a background worker that could run for 20 minutes or 2 hours. On a local machine, you're one forced macOS update away from losing your session.
Running the agent where it belongs: a persistent remote shell
I moved my AI coding agent to a cheap Linux VPS. The box stays on 24/7, never sleeps, and doesn't throttle because I'm not also running Chrome with 40 tabs there. The agent runs inside a tmux session. I attach and detach over SSH.
The workflow looks like this:
# On my laptop, connect and rejoin the agent's session
ssh myserver -t tmux attach -t agent
Inside that tmux session, I launch the agent with whatever project context it needs. If my WiFi drops, no problem. If I close my laptop, the agent keeps chewing on the task. I can reconnect hours later, scroll up, and see exactly what it did.
Asynchronous development, for real
This changed how I think about development time. I start a task before a meeting, detach, and check the result when I'm back. I fire off a large migration at the end of the day and review the diff in the morning. The agent becomes an async collaborator that works while I'm away.
You don't need any special software. The tooling is already in your fingers: SSH, tmux, and maybe git. If you want to push code to the remote environment, rsync or a quick git push and git pull keeps things in sync. Or you do all your editing remotely with Neovim or Emacs inside that same session.
The machine that never sleeps is a $7 commodity
The compute requirements for most AI coding agents are modest (a couple of CPUs, 2 to 4 GB RAM). A low-end VPS handles it easily. The real value is persistence.
I happen to use xShellz for this because they offer preconfigured remote Linux shells with tmux and common tooling already set up, and the processes stick around even when you disconnect. You can grab a shell, drop your agent in, and walk away. It's not the only way to do it. Any VPS where you can run a long-lived tmux session works.
The point is that your laptop stops being the runtime. It becomes a thin client that attaches to a persistent environment. My machine suddenly became a terminal and a browser, and the heavy lifting happens somewhere that doesn't care if I close the lid.
Takeaway
If your AI coding agent dies because your battery did, the problem isn't the agent. It's where you run it. Moving to a remote shell that doesn't sleep, throttle, or get killed by power management turns the agent into a reliable background worker. I'll never go back to running long tasks locally again.