pymobiledevice3 lockdown¶
Pair/unpair, read and change device values, and talk to raw lockdown services.
recovery¶
Reboot the device into recovery mode.
The device leaves normal iOS and waits in recovery; use restore exit
to boot it back normally.
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
service¶
Open an IPython shell on a raw lockdown service, to send and receive its messages.
Arguments:
| Argument | Description |
|---|---|
service_name |
Lockdown service name (e.g. com.apple.mobile.diagnostics_relay). [required] |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
developer-service¶
Open an IPython shell on a raw developer service (needs the DeveloperDiskImage mounted).
Arguments:
| Argument | Description |
|---|---|
service_name |
Developer service name (e.g. com.apple.instruments.remoteserver). [required] |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
info¶
Print all lockdown values (device name, iOS version, UDID, ...).
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
get¶
Print a lockdown value, or every value of a domain.
Arguments:
| Argument | Description |
|---|---|
domain |
Value domain (e.g. com.apple.mobile.battery); omit for the global domain. |
key |
Key to read; omit to read the whole domain. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
set¶
Change a lockdown value on the device.
VALUE is parsed as a Python literal (with ast.literal_eval), so quote strings, e.g. "'My iPhone'".
Arguments:
| Argument | Description |
|---|---|
value |
New value as a Python literal (e.g. True, 42, 'text'). [required] |
domain |
Value domain; omit for the global domain. |
key |
Key to set. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
remove¶
Remove a lockdown value from the device.
Arguments:
| Argument | Description |
|---|---|
domain |
Value domain. [required] |
key |
Key to remove. [required] |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
unpair¶
Unpair a host from the device and forget its local pair record.
The device asks to "Trust This Computer" again on the next pairing.
Arguments:
| Argument | Description |
|---|---|
host_id |
HostID of the pairing to remove; omit to remove this host's pairing. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --usbmux, --udid.
pair¶
Pair this computer with the device (accept "Trust This Computer" on the device).
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --usbmux, --udid.
pair-supervised¶
Pair with a supervised device using its supervision identity (no Trust dialog).
Arguments:
| Argument | Description |
|---|---|
keybag |
PEM file with the supervisor's private key and certificate (see profile create-keybag). [required] |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --usbmux, --udid.
save-pair-record¶
Save this host's pair record for the device to a file (it grants access to the device).
Arguments:
| Argument | Description |
|---|---|
output |
File to write the pair record (plist) to. [required] |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --usbmux, --udid.
date¶
Print the device's current date and time.
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
heartbeat¶
Keep a lockdown heartbeat going with the device; runs until Ctrl+C.
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
language¶
Print the device language, or change it first if LANGUAGE is given.
Arguments:
| Argument | Description |
|---|---|
language |
Language code to set (e.g. en); omit to only print it. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
locale¶
Print the device locale (region format), or change it first if LOCALE is given.
Arguments:
| Argument | Description |
|---|---|
locale |
Locale to set (e.g. en_US); omit to only print it. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
device-name¶
Print the device name, or rename the device.
Arguments:
| Argument | Description |
|---|---|
new_name |
New device name; omit to print the current one. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
wifi-connections¶
Show or set whether this host may connect to the device over Wi-Fi (EnableWifiConnections).
Arguments:
| Argument | Description |
|---|---|
state:<on\|off> |
Turn it on or off; omit to print the current state. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
start-tunnel¶
Start an iOS 17.4+ tunnel over lockdown and print its --rsd HOST PORT (needs root).
Rarely needed: commands build their own no-root tunnel. Use it when another process needs --rsd. Always uses TCP. Runs until Ctrl+C.
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
--script-mode / --no-script-mode |
Print only HOST and port, for parsing from shell scripts. [default: no-script-mode] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
remotepairing¶
Print the device's RemotePairing handshake info; with --pair, also pair.
Performs a RemotePairing handshake over the
com.apple.dt.remotepairingdeviced.lockdown control channel and prints the
device's handshake info (peer device info, wire protocol versions, pairing
capabilities). This control channel does not create tunnels - use
start-tunnel for that.
With --pair, performs RemotePairing pair-setup when the device is not
already paired. Because this runs over the already-trusted lockdownd (USB)
transport, pairing is promptless - no Trust dialog is shown - and it writes
the RemotePairing pair record used by pymobiledevice3 remote start-tunnel,
letting you bootstrap that record over USB without any on-device
interaction.
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
--pair |
Perform RemotePairing pair-setup if not already paired (promptless over lockdownd). |
--raw |
Do not decode the base64 deviceKVSData blob. |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
assistive-touch¶
Show or set whether the AssistiveTouch button is shown on screen.
Arguments:
| Argument | Description |
|---|---|
state:<on\|off> |
Show or hide it; omit to print the current state. |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.
auto-answer¶
Set whether incoming calls are answered automatically (Accessibility > Call Audio Routing).
Arguments:
| Argument | Description |
|---|---|
state:<on\|off> |
Turn auto-answer on or off. [required] |
Options:
| Option | Description |
|---|---|
--native |
macOS only: reach the iOS 17+ tunnel by piggybacking Apple's own remoted tunnel via the remotepairingd service. NO root, no entitlement, no Xcode. Rides Apple's kernel-routable tunnel, so throughput matches the kernel tunnel, but the device keeps a single RSD connection on it: remoted and this process evict each other's, which can reset connections and leave Xcode/devicectl without the device until remoted reconnects. Mutually exclusive with --rsd/--tunnel/--userspace. [env var: PYMOBILEDEVICE3_NATIVE] |
Accepts the connection options: --rsd, --tunnel, --userspace, --mobdev2, --usbmux, --udid.