Show Notes
Cursor background agents and the Remote Cursor Protocol (RCP) open up a new way to run and orchestrate AI-assisted code inside a remote environment. This feature is in beta, per-project, and promises to drastically speed up development once you configure it properly.
What Cursor’s background agents are (and what RCP means)
- Remote Cursor Protocol (RCP) is not traditional RPC. It’s a protocol to expose and control a Cursor instance from an external agent.
- Background agents run async tasks that can edit and execute your code in a remote environment.
- You interact with agents via a prompt-driven flow (press the apostrophe to submit a prompt, then view status and the machine the agent is running on).
How to turn it on and what you’ll see
- Enable beta access: Cursor > Beta features > turn on Early Access.
- Per-project scope: the agent setup is defined per repository/project.
- You configure a port and an optional access token, then persist that configuration in the project. Restart Cursor to apply.
How it works under the hood
- Think of it as a controlled “external service” access point into your project’s behavior. It’s similar in spirit to having an MCP-style server library you can attach to your repo.
- The system uses a per-project environment JSON to describe the machine that will run the agent. This is akin to a Docker/dev-container setup but stored inside your repo.
- The environment JSON supports:
- Base image (e.g., Ubuntu)
- Dockerfile/Container/Snapshot specs
- Maintenance commands to keep the machine updated
- Manual installation steps for repo dependencies
- Start commands and terminal sessions shared with the agent
- Agents clone from your GitHub repo, work on a separate branch, and push changes back as appropriate.
- Machines are effectively VMs you offload to the cloud or a remote host; you can run multiple VMs/work trees to segment context.
Example (conceptual) environment JSON snippet:
json
{
"baseImage": "ubuntu:22.04",
"dependencies": [
"nodejs",
"python3",
"build-essential"
],
"setupCommands": [
"apt-get update",
"apt-get install -y build-essential git"
],
"startCommands": [
"npm install",
"npm run start"
],
"maintenanceCommands": [
"apt-get update && apt-get upgrade -y"
],
"snapshot": true
}
- Live commits to the environment config are encouraged; the setup flow guides you through creating a robust environment JSON.
- A “base environment” defines the machine’s hard drive and OS footprint; you’ll run inside a Ubuntu image by default.
Use cases you’ll likely care about
- Custom ID extensions and plugins (extend Cursor with domain-specific tooling).
- Automated code review bots that run in the background as changes come in.
- CI/CD-style automation and document generation tied to repository events.
- Memory of context and tooling (more on memory banks below) to keep agents productive across tasks.
Onboarding a new machine and managing agents
- First-time usage in a new repo feels like onboarding a new employee: you set up the machine, install dependencies, and then you’re ready to hand it a task.
- The UI exposes “advanced options” and automation controls, but initial setup emphasizes getting the environment right so the agent isn’t constantly redoing setup work.
- Terminals in the agent run in a shared tmux-like session, so you and the agent can see the same workspace.
Environment management, dev containers, and snapshots
- The flow is very Docker/Dev Containers-like: you define how the machine is built, what’s installed, and what gets started.
- Snapshots persist the disk state, enabling reproducible runs.
- Don’t copy your project into the machine image; clone it inside the environment to keep things clean and reproducible.
- If your dev stack relies on Docker, you can start the docker service inside the environment so you can build/run containers from the agent.
Security, costs, and practical guardrails
- Background agents expand the surface area: you grant read/write access to your repo, and you run commands in a VM you control.
- Expect prompts around authentication, access tokens, and what the agent can do. Plan for per-project permissions and auditing.
- Auto-run commands and potentially exfiltration-aware settings exist; use maintenance commands and per-project limits to keep things in check.
- Pricing path: model- and environment-compute choices will influence cost. Higher-perf modes will be more expensive.
- Best practices:
- Fully configure the machine before heavy use to avoid idle, wasteful agent activity.
- Use per-project environments to keep context scoped and auditable.
- Consider setting sensible spending alerts or limits if the platform supports them.
Developer workflow tips and practical takeaways
- Pay down the “ignorance tax” upfront: invest time to set up robust environments and memory contexts so the agent can work efficiently later.
- Use memory banks to keep contextual knowledge across tasks and repos:
- Create a memory bank per major area (e.g., monorepo components, microservices, etc.).
- This helps agents reuse context without repeatedly reloading identical data.
- Plan around product requirements with PRD prompts:
- A strong PRD prompt can help you surface open questions and refine specs before you start implementing with agents.
- If you want my PRD prompt template, comment PRD and I’ll share it.
- Expect onboarding to be iterative: early days will involve tweaking environment JSON, permissions, and startup flows to fit your stack.
- Be mindful of branching: agents can work on dedicated branches; keep feature work isolated for clean collaboration.
Practical next steps
- If you’re curious, join the Cursor community on Discord to discuss onboarding and real-world usage.
- If you want the PRD prompt mentioned in the video, drop a comment with PRD to signal interest.
- Note: there are promos and ongoing discussions around related tooling (e.g., Claude Code) that may offer temporary discounts or extended trials.
Links
- Cursor AI (background agents and RCP docs)
- Cursor Changelog (beta features and setup guidance)
- Claude Code (AI coding assistant by Anthropic)
- Claude Code Documentation (official docs)
- Cursor Discord (community resources and discussions)
If you found this helpful, consider subscribing for more concise breakdowns of upcoming AI/development tooling and practical tips for adopting agent-oriented workflows.