free field guide quality-control
Let an AI Agent Test Your Android App
Set up Google's free Artemis tool so an AI agent taps through your app on a real phone or emulator, then read the replay to find where it breaks.
Let an AI Agent Test Your Android App
Artemis is a free, open-source tool from Google that lets an AI agent see an Android screen and tap through it like a person would. You watch every tap live, then read the replay and logs to find the exact screen where your app breaks.
What this helps you do
Asking an AI "does my app look okay?" only checks the code. Artemis checks the real thing. The agent opens your app on a phone or emulator, follows your instructions, and records what happened at each step.
Use it to test a sign-up flow, a checkout, or any path a user takes before you ship. You can run it from a browser console or connect it to Claude Code or Codex so your coding agent can test its own changes.
Before you start
- A Mac, Linux, or Windows computer with Git.
- An Android phone with USB debugging on, or an emulator. To turn on USB debugging, follow Android's developer options guide: tap Build number seven times, then turn on USB debugging in Developer options. For an emulator, install Android Studio and create a virtual device.
- A USB cable that carries data, if you use a real phone.
- An API key from one AI model provider. Artemis works with Gemini, OpenAI, Anthropic, OpenRouter, or xAI keys. You add one during setup. Each test uses that provider's paid API.
- A test account for your app. Never let the agent use real customer data or your personal logins.
- Claude Code or Codex, if you want your coding agent to drive the phone. This part is optional.
Terms to know
- Emulator: a pretend Android phone that runs on your computer.
- USB debugging: an Android setting that lets your computer control the phone and read its logs.
- ADB: Android Debug Bridge, the standard tool that sends those commands. The setup script installs it for you.
- MCP: Model Context Protocol, the connection that lets Claude Code or Codex use Artemis as a tool.
- Replay: a recording of every step the agent took, so you can see what it saw.
- Logcat: Android's system log. It shows errors and crashes behind the scenes.
Step-by-step
- Plug in your phone with USB debugging on, or start your emulator.
- Open a terminal on a Mac or Linux and paste:
Copy this
git clone https://github.com/google/artemis.git && cd artemis
./start.shOn Windows, open PowerShell instead and run these two lines:
Copy this
git clone https://github.com/google/artemis.git
cd artemis
.\start.bat- The script checks for and installs ADB, scrcpy, FFmpeg, and the Python tools it needs. It also creates a settings file called
.envin theartemisfolder. - When it asks whether to set up AI coding tools, say yes for Claude Code or Codex if you use them. You can do this later too.
- Open the
.envfile in a text editor and paste your key after one provider line, such asGEMINI_API_KEY=orANTHROPIC_API_KEY=. Save it. - Your browser opens
http://localhost:8000with a device connection wizard. On the phone, accept the Allow USB debugging? prompt. You should see a live view of the phone screen in your browser. - Start with a simple task to prove it works, like "Open Settings, find Battery and tell me the current level." Watch the agent tap through it.
- Install your app on the phone, then give it a real test using the prompt in Copy this.
- When it finishes, open the replay. Step through it to see each screen, each tap, and where the flow stopped.
Connect Claude Code later
If you skipped it during setup, run this from inside the artemis folder:
Copy this
uv run artemis mcp --install claudeRestart Claude Code. Now you can ask it to install your latest build on the phone and test a flow, all from your chat.
Copy this
Paste this into the Artemis browser console, or into Claude Code once Artemis is connected. Replace the bracketed parts.
Copy this
Open [APP NAME]. Sign up with this test account: email [TEST EMAIL], password [TEST PASSWORD]. Complete every step of sign-up until you reach [WHAT A FINISHED SIGN-UP LOOKS LIKE, e.g. the home screen].
Report:
1. Each screen you saw, in order
2. The exact screen and button where the flow got stuck or behaved unexpectedly
3. Any error messages, popups, or crashes, with screenshots
4. Anything a first-time user would find confusing
Use only the test account. Do not make purchases, send messages, or change account settings outside the sign-up flow.Things to know
- Flash or Pro. Artemis has two modes. Flash is fast, about 3 to 5 seconds per step, and fits routine checks. Pro plans the test, checks each action before it taps, and can write a report, at about 15 to 40 seconds per step.
- It installs a small helper on the phone. You'll see an "Artemis test helper is running" notification and a new entry in Accessibility settings. It reads the screen layout on the phone itself. Remove it any time with
uv run artemis helper uninstall. - The phone stays awake during tests. Use a spare or test phone if you can.
- Each step costs model usage. Longer tests and Pro mode use more of your API budget.
- Watch the first runs. The agent taps real buttons. Keep tests inside your own app and a test account.
- It's free and open source under the Apache 2.0 license. Source and full docs live on the Artemis GitHub page.
If something goes wrong
- No device found: check the cable carries data, accept the debugging prompt on the phone, and confirm USB debugging is still on. Then run
uv run artemis doctorin theartemisfolder for a list of what's missing. - The agent can't start a task: the API key is usually missing or mistyped. Recheck the
.envfile, runuv run artemis doctorto test it, then restart withuv run artemis restart. - The browser page didn't open: open
http://localhost:8000yourself. - Windows says the script isn't found: in PowerShell type
.\start.bat. In Command Prompt typestart.bat. - Claude Code doesn't see Artemis: run the connect command above, then fully restart Claude Code.
Final check
You pass when the live phone view shows in your browser, the agent finishes your sign-up test on a test account, and the replay shows you the exact screen where the flow worked or got stuck.