Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

idb logo

CI Discord

The "iOS Development Bridge" or idb, is a command line interface for automating iOS Simulators and Devices. It has three main principles:

  • Remote Automation: idb is composed of a "companion" that runs on macOS and a python client that can run anywhere. This enables scenarios such as a "Device Lab" within a Data Center or fanning out shards of test executions to a large pool of iOS Simulators.
  • Simple Primitives: idb exposes granular commands so that sophisticated workflows can be sequenced on top of them. This means you can use idb from an IDE or build an automated testing scenario that isn't feasible with default tooling. All of these primitives aim to be consistent across iOS versions and between iOS Simulators and iOS Devices. All the primitives are exposed over a cli, so that it's easy to use for both humans and automation.
  • Exposing missing functionality: Xcode has a number of features that aren't available outside its user interface. idb leverages many of Private Frameworks that are used by Xcode, so that these features can be in GUI-less automated scenarios.

idb is built on top the FBSimulatorControl and FBDeviceControl macOS Frameworks, contained within this repository. These Frameworks can be used independently of idb, however idb is likely to provide the simplest install and the most sensible defaults for most users.

We've given a talk about idb at F8, so that you can learn more about what idb is and why we built it. A recording of the talk is available here.

Quick Start

idb is made up of 2 major components, both of which are installed by a single brew formula.

idb companion

Each target (simulator/device) will have a companion process attached allowing idb to communicate remotely.

The idb companion can be installed via brew or built from source

brew install facebook/fb/idb

Note: Instructions on how to install brew can be found here

idb client

A cli tool and python client is provided to interact with idb.

It is installed alongside the companion by the brew formula above. It can also be installed separately via pip (releases publish to PyPI):

pip3 install fb-idb

Note: The idb client requires python 3.11 or greater to be installed.

Please refer to fbidb.io for detailed installation instructions and a guided tour of idb.

Once installed, just run the list-targets command which will show you all the simulators installed on your system:

$ idb list-targets
...
iPhone X | 569C0F94-5D53-40D2-AF8F-F4AA5BAA7D5E | Shutdown | simulator | iOS 12.2 | x86_64 | No Companion Connected
iPhone Xs | 2A1C6A5A-0C67-46FD-B3F5-3CB42FFB38B5 | Shutdown | simulator | iOS 12.2 | x86_64 | No Companion Connected
iPhone Xs Max | D3CF178F-EF61-4CD3-BB3B-F5ECAD246310 | Shutdown | simulator | iOS 12.2 | x86_64 | No Companion Connected
iPhone Xʀ | 74064851-4B98-473A-8110-225202BB86F6 | Shutdown | simulator | iOS 12.2 | x86_64 | No Companion Connected
...

list-apps will show you all the apps installed in a simulator:

$ idb list-apps --udid 74064851-4B98-473A-8110-225202BB86F6
com.apple.Maps | Maps | system | x86_64 | Not running | Not Debuggable
com.apple.MobileSMS | MobileSMS | system | x86_64 | Not running | Not Debuggable
com.apple.mobileslideshow | MobileSlideShow | system | x86_64 | Not running | Not Debuggable
com.apple.mobilesafari | MobileSafari | system | x86_64 | Not running | Not Debuggable

launch will launch an application:

$ idb launch com.apple.mobilesafari

Head over to the main documentation for more details on what you can do with idb and the full list of commands. There are also instructions on how to make changes to idb including building it from source.

Building from Source

Prerequisites

  • macOS 15+ with Xcode 26.0+
  • XcodeGen: brew install xcodegen
  • For idb_companion: protobuf and gRPC Swift plugins
    brew install protobuf swift-protobuf grpc-swift
    

Building

# Build everything: frameworks, shims, SimulatorFrameworkBridge, ReplHost and
# idb_companion, then assemble the runnable distribution
./build.sh build

# Build only the frameworks
./build.sh build frameworks

# Build the shim dylibs (Shimulator + Repl, iOS + macOS)
./build.sh build shims

# Build only idb_companion
./build.sh build idb_companion

# Build a specific framework
./build.sh build FBControlCore

The individual build products are written under Build/Products/Release. A full ./build.sh build also assembles a self-contained distribution at Build/Distribution, laid out the way idb_companion expects at runtime:

Build/Distribution/
  idb_companion              # the executable
  *.framework               # frameworks, resolved via @executable_path
  Resources/
    libShimulator-iOS.dylib
    libShimulator-macOS.dylib
    libRepl-iOS.dylib
    libRepl-macOS.dylib
    SimulatorFrameworkBridge
    ReplHost.app
    IDBAPI.swiftinterface

idb_companion discovers the shims and SimulatorFrameworkBridge from the Resources directory next to the executable, so run it from Build/Distribution (or copy that directory as a unit).

Running Tests

# Run all tests
./build.sh test

# Test a specific framework
./build.sh test FBSimulatorControl

Regenerating Xcode Projects

The Xcode project files are generated from project.yml using XcodeGen. To regenerate without building:

./build.sh generate

Build Script Reference

./build.sh help                          # Show all options
./build.sh generate                      # Regenerate Xcode projects
./build.sh build                         # Build all targets and package the distribution
./build.sh build distribution            # Assemble Build/Distribution from built products
./build.sh build frameworks              # Build all frameworks
./build.sh build idb_companion           # Build idb_companion
./build.sh build shims                   # Build all shim dylibs (Shimulator + Repl, iOS + macOS)
./build.sh build SimulatorFrameworkBridge # Build the SimulatorFrameworkBridge helper
./build.sh build FBControlCore           # Build specific framework
./build.sh test                          # Run all tests
./build.sh test FBSimulatorControl       # Test specific framework

Documentation

Find the full documentation for this project at fbidb.io

We also have a public Discord Server that you can join

Contributing

We've released idb because it's a big part of how we scale iOS automation at Facebook. We hope that others will be able to benefit from the project where they may have needs that aren't currently serviced by the standard Xcode toolchain.

Code of Conduct

Facebook has adopted a Code of Conduct that we expect project participants to adhere to. Please read the full text so that you can understand what actions will and will not be tolerated.

Contributing Guide

Read our contributing guide to learn about our development process.

License

idb is MIT-licensed.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

fb_idb-1.5.0b3.tar.gz (113.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

fb_idb-1.5.0b3-py3-none-any.whl (170.2 kB view details)

Uploaded Python 3

File details

Details for the file fb_idb-1.5.0b3.tar.gz.

File metadata

  • Download URL: fb_idb-1.5.0b3.tar.gz
  • Upload date:
  • Size: 113.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for fb_idb-1.5.0b3.tar.gz
Algorithm Hash digest
SHA256 9cc55ea5e44810f9689a129c2504f49566512a1574ea3adb292d6d74fe9d8779
MD5 0199b8a66c8baa9db4692eb4cdbbb188
BLAKE2b-256 c8fb0e48868e095ecf4a68d9adc1f9090f4bbd73854ba349e05a25c260fa779e

See more details on using hashes here.

Provenance

The following attestation bundles were made for fb_idb-1.5.0b3.tar.gz:

Publisher: release.yml on facebook/idb

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file fb_idb-1.5.0b3-py3-none-any.whl.

File metadata

  • Download URL: fb_idb-1.5.0b3-py3-none-any.whl
  • Upload date:
  • Size: 170.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for fb_idb-1.5.0b3-py3-none-any.whl
Algorithm Hash digest
SHA256 da570d9be6b51f7bfc6c55fa7f008c1962a75b3da1459b069a3e6a16bfa4078b
MD5 76e60c920e8a50c2db74de40f1b5b8da
BLAKE2b-256 d1062589b5dd8b2d0619d4057e72c2e9446c1f42d3a2e6378f5495ba06677af1

See more details on using hashes here.

Provenance

The following attestation bundles were made for fb_idb-1.5.0b3-py3-none-any.whl:

Publisher: release.yml on facebook/idb

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

1.5.4

2 files

1.5.3

2 files

1.5.2

2 files

1.5.1

2 files

This release

1.5.0b3 This release

2 files

1.1.7

2 files

1.1.6

2 files

1.1.5

2 files

1.1.4

2 files

1.1.2

2 files

1.0.13

2 files

1.0.12

2 files

1.0.11

2 files

1.0.10

2 files

0.0.7

2 files

0.0.6

2 files

0.0.5

2 files

0.0.4

2 files

0.0.3

2 files

0.0.2

2 files

0.0.1

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page