AXe 2: physical devices, iPhone Duo simulator and agent mode
AXeAXe

iOS automation
for simulators, devices & agents

One CLI for iOS simulators, including the dual-screen iPhone Duo simulator, and connected iPhones and iPads. Read the accessibility tree, tap, type, swipe and draw, capture screenshots and video, and change device settings. Agent mode gives AI agents checked, stateful control of the UI.

MIT LicensedSingle BinarySimulators & DevicesXcode 26 & 27AI Agent Ready

One set of commands, one set of error codes, every target

iOS Simulator

iPhone and iPad simulators on Xcode 26 and 27, in every orientation.

iPhone Duo Simulator

Both screens of the dual-screen iPhone Duo simulator, in every fold and orientation, with hinge control.

iPhone & iPad

Connected devices over Xcode's CoreDevice. Pass the hardware UDID to the same commands.

Everything you need for iOS automation

Read the screen, drive any input, capture the result and configure the device, from your terminal.

Accessibility Reads

The full accessibility tree as JSON, or the element at one point. Tap by ID, label or value, and wait for elements to appear.

Touch & Gestures

Taps, long presses, double and two-finger taps, swipes, scroll-until-visible, pinch, rotate, drag to reorder and one-finger drawing.

Text & Keyboard

Type text from an argument, stdin or a file. Single keys, key sequences and shortcuts such as Cmd+A by HID key code.

Screenshots & Video

PNG screenshots, H.264 MP4 recording, MJPEG, JPEG and BGRA streams, and native H.264 from a physical device.

Device Settings

Dark mode, text size, contrast, reduce motion, colour filters, VoiceOver, a simulated location and a clean status bar.

Structured Output

Put --output json before any command for one typed result, or a typed error code to branch on. JSON Schemas describe every result.

Buttons & Rotation

Home, lock, side button, Siri and Apple Pay. Rotate the iPhone Duo simulator or a physical device and wait for the new orientation.

Batch Automation

Run many input steps in one command and one input session, with selector waiting between steps.

Agent Mode

Compact captures with refs, actions checked against the screen the agent saw, and the settled screen in every reply.

Simple & Powerful

Intuitive CLI commands

Every interaction is one command with an explicit target. Coordinates are points in the current orientation, and AXe handles rotation, letterboxing and each iPhone Duo simulator screen for you.

  • Selector taps by accessibility ID, label or value, with waiting
  • Scroll until an element is on screen, then stop exactly there
  • Gesture presets that measure the real screen size
  • Text from arguments, files or stdin for flexible scripting
Terminal
# Tap by accessibility label, waiting for it to appear
$ axe tap --label "Sign In" --wait-timeout 5 --udid $UDID
# Scroll until an element is on screen
$ axe gesture scroll-up --until-label "Privacy" --udid $UDID
# Long press, then pinch to zoom
$ axe tap --label "Photo" --hold 1 --udid $UDID
$ axe gesture pinch --scale 2 --udid $UDID
# Dark mode and a large text size
$ axe settings set --appearance dark --text-size accessibility-large --udid $UDID
# Typed JSON result
$ axe --output json screenshot --output screen.png --udid $UDID
agent session
# Capture the screen as rows with refs
$ axe describe-ui --agent --view navigation --udid $UDID
snapshotID 3FF70D78-…
e7|tap|text-field|First name|
e9|tap|text-field|Last name|
e12|tap|button|Save|
# Fill the form in one checked call
$ axe batch --agent --udid $UDID --steps-json '{"snapshotID":"3FF70D78-…","steps":[{"action":"type","ref":"e7","text":"Ada","focus":true},{"action":"type","ref":"e9","text":"Lovelace","focus":true},{"action":"tap","ref":"e12"}]}'
completedSteps 3 · input checked before every step
returns the settled screen with a new snapshot
New in AXe 2

Agent mode for AI agents

Add --agent and every read and action is checked. AXe confirms the control is still the one the agent saw, sends the input and returns the new screen, so an agent never taps the wrong thing after a layout change and needs no extra read.

  • Compact rows with a ref for each control, in navigation, reading or full views
  • Refusals send no input and carry a typed code with the current screen
  • Batch up to eight same-screen taps and types in one call
  • Focus a field and type in one command
  • No model or API key required
Read the agent mode guide
New in AXe 2

Real devices & dual screens

Automate connected iPhones and iPads, and every screen and fold of the iPhone Duo simulator, with the commands you already use.

Physical iPhone & iPad

Pass the hardware UDID to screenshots, accessibility reads, selector taps, gestures, typing, buttons, batches, rotation, settings and video, including native H.264. doctor tells you exactly what a device still needs.

$ axe list-devices
$ axe doctor --udid $DEVICE
$ axe tap --id Continue --wait-timeout 15 --udid $DEVICE
$ axe stream-video --format h264 --udid $DEVICE > screen.h264

iPhone Duo Simulator

Every input, read and capture command works on the dual-screen simulator, on whichever screen is active, in any fold and orientation. Show the screens, move the hinge, rotate, guard input to one screen, and record one movie through every fold.

$ axe displays --udid $UDID
$ axe hinge set tabletop --udid $UDID
$ axe rotate left --udid $UDID
$ axe record-video --follow-active-display --udid $UDID

Built for AI agents

The AXe skill teaches your coding agent to test and operate iOS apps with agent mode.

AI Skill

One command setup

Run axe init to install the skill bundled with your binary, or add the AXe plugin marketplace to Claude Code or Codex so the skill stays updated as releases ship.

$ axe init
$ claude plugin marketplace add cameroncooke/AXe && claude plugin install axe@axe
$ codex plugin marketplace add cameroncooke/AXe && codex plugin add axe@axe
Agent Example

Autonomous testing

Agents capture the screen, act on refs, batch same-screen actions and verify from the screen each action returns.

> Sign up a new user and check the welcome screen
Captured the sign-up form (navigation view)
Filled name, email and password in one batch
Tapped "Create Account"; reply returned the new screen
Read the welcome text from the returned capture
Sign-up works. The welcome screen shows "Welcome, Ada".

Works with your favourite AI tools

Claude CodeCodexCursorVS CodeShell ScriptsCI
Faster in AXe 2

Simulator input in milliseconds

Measured on an iPhone 18 Pro simulator against AXe 1.8.

Tap
0.08 s
was about 1 s
Drag
0.9 s
was 2.5 s
describe-ui
0.3 s
was 1.1 to 1.9 s

Why AXe?

Practical iOS automation for terminals, scripts, CI jobs and AI agents.

Terminal Native

Shell commands that fit scripts, CI jobs and agent workflows. No server, no test target, no app changes.

Safe by Design

AXe never picks a device for you, never replays uncertain input, and blocks input if a touch might still be held.

Fast

A warm input connection is reused across commands, so a simulator tap takes about 80 ms.

Typed Errors

Simulators and devices share one error vocabulary. Branch on error.code, not on message text.

Agent First

Agent mode, a bundled skill and plugin marketplaces make AXe the iOS hands for your coding agent.

Accessibility First

Built on Apple's accessibility APIs. Target elements by ID or label, not just coordinates.

Get started in seconds

Install AXe with Homebrew. Requires macOS 14 or later and Xcode 26 or 27.

Install with Homebrew:

brew install cameroncooke/axe/axe

Check a booted simulator or connected device:

axe doctor --udid <UDID>

Teach your AI agent to use AXe:

axe init
AXe

Open source, community driven

AXe is MIT licensed and welcomes contributions. Help shape the future of iOS automation.