To give GitHub Copilot’s agent mode an Android phone in VS Code, add the Mobilebox MCP server at https://mobilebox.dev/mcp: one click with the install link below and a browser sign-in, or one entry in ~/.copilot/mcp-config.json with your API key read from the environment. Copilot then has 14 phone tools: it starts a cloud Android phone, installs your APK, reads the screen, taps, types, takes screenshots and stops the phone.
One click: install and sign in
Add Mobilebox to VS Code. VS Code opens the server’s details so you can check the URL before you install. On first use it signs in over MCP OAuth: a browser window opens, you sign in to Mobilebox and choose Allow. No key to copy. The connection shows under API keys in the Mobilebox dashboard, where you can revoke it.
Or let the agent set it up
Paste this into Copilot Chat in agent mode:
Set up Mobilebox for me: read https://mobilebox.dev/setup.md and follow it.It asks for your email, gets a key at once, stores it without printing it and adds the server; the 6-digit code from your inbox keeps the workspace.
With an API key
Put your key in your shell profile as MOBILESANDBOX_API_KEY (sign up and create one in the dashboard) and start VS Code from a terminal that has it. VS Code now points new servers to the Copilot format: ~/.copilot/mcp-config.json (or $COPILOT_HOME/mcp-config.json), the same file GitHub Copilot CLI reads.
{
"mcpServers": {
"mobilebox": {
"type": "http",
"url": "https://mobilebox.dev/mcp",
"headers": { "Authorization": "Bearer ${MOBILESANDBOX_API_KEY}" }
}
}
}Write the variable with braces. VS Code’s MCP client reads a bare $MOBILESANDBOX_API_KEY as literal text, and the header would carry those letters instead of your key.
For a team: commit the server, not the key
.vscode/mcp.json in the repository uses VS Code’s own format, with servers and a type. Leave the header out and each person signs in over OAuth the first time Copilot uses a phone:
{ "servers": { "mobilebox": { "type": "http", "url": "https://mobilebox.dev/mcp" } } }Prompted keys (${input:…}) also work in this file, but VS Code doesn’t forward servers that need them to Copilot harness sessions, so OAuth or the environment variable is the safer choice.
Check it
Run MCP: List Servers from the Command Palette: Mobilebox should be running. In the chat box, the tools button lists its tools. After a run, expand a tool call to see that it went to Mobilebox. Copilot asks before tool calls; Chat: Manage Tool Approval lets you trust some or all of the server’s tools.
Visual Studio, JetBrains and Xcode keep Copilot’s servers in their own mcp.json with a servers key; GitHub’s docs show the exact shape for each, including where the header goes.
The formats are from VS Code’s MCP configuration reference, its MCP server guide and GitHub’s Copilot MCP docs, reviewed on November 10, 2026. We didn’t run VS Code itself; the endpoint and header are the ones every client on this site uses.
A first task
Start a Mobilebox phone, install the APK at <your APK URL>, walk the sign-up flow, take a screenshot of each step, then stop the phone.Copilot calls create_phone, which returns the first screen, then install_app with your URL. For each step it calls act to tap or type and reads the new screen it gets back, and screenshot for the pictures. Stopping is park_phone: the phone stops billing and keeps the app and its login for the next run. Say "delete the phone" when you want nothing kept. watch_phone gives you a link to watch it work. The mental model: a phone per agent per PR, started, checked, screenshotted, stopped.
What it costs
A phone costs $0.01 a minute while it is ready, billed per second with a one-minute minimum. Boot time and parked phones are free. On our November 8 benchmark one tap plus a fresh screenshot took 1.45 s at the median, so most of a run is your model thinking between steps. A sign-up walk that keeps the phone ready for 3 minutes costs 3 cents; our framework examples finished their short task in 31 to 38 seconds, about a cent. The agent guide covers the observe, act, verify loop in full.