Mistake on this page?
Report an issue in GitHub or email us


We recommend installing Mbed CLI with our installer. If you need more customization, you can perform a manual install.

Prebuilt Mbed CLI installer

Download and run the macOS installer for Mbed CLI.

Tip: Mbed CLI may not work properly without some manual configuration of compiler, Git and Mercurial paths.

Manual installation

1. Download and install prerequisites

  • Python: Mbed CLI is a Python script, so you'll need Python to use it. We test Mbed CLI with Python versions 2.7.11, and with 3.6.5 and greater.

    macOS 10.8+ comes with Python 2.7 preinstalled by Apple. If you are running an earlier version of macOS, download and install Python versions 2.7.11 or 3.6.5 or later.

    Note: Python 3 usage is not compatible with Mbed OS versions older than 5.9 and Mbed CLI toolchain versions older than 1.7.2.

  • pip.

    To install Pip, run easy_install --user pip from your command-line.

    Note: Mbed CLI toolchain versions older than 1.5.1 are not compatible with pip version 10.0 (or newer). Please use the latest Mbed CLI with newer version of pip.

  • Git and Mercurial: Mbed CLI supports both Git and Mercurial repositories, and you may need libraries from both sources as you work, so please install both:

    • Git - version 1.9.5 or greater.
    • Mercurial - version 2.2.2 or greater.

Optional: Using a virtual environments

If your main environment has an unsupported Python version, you may want to install Mbed CLI on a virtual environment. Mbed CLI is compatible with Virtual Python Environment (virtualenv).

2. Install a compiler

Download and install one of the following compilers: GCC Arm, Arm Compiler 5, Arm Compiler 6 or IAR. To download the latest toolchains, visit the supported compilers page.

3. Install Mbed CLI

To install Mbed CLI, run pip install mbed-cli --user from your command-line.

You can verify Mbed CLI installed correctly by running mbed --version.

Note: You may also need to add the new Mbed CLI Python --user installation location (for example: /Users/{username}/Library/Python/2.7/bin) to the PATH.

4. Set up the environment

For any installed toolchain, be sure to add the Mbed CLI global configuration:

$ mbed config -G ARM_PATH <path to ARM bin\>"
[mbed] <path to ARM bin\> now set as global ARM_PATH

$ mbed config --list
[mbed] Global config:
ARM_PATH=<path to ARM bin\>

Note: You can also apply the same configuration to the IAR and GNU toolchains using IAR_PATH or GCC_ARM_PATH.

Tip: Mbed CLI may not work properly without some manual configuration of compiler, Git and Mercurial paths.

Important Information for this Arm website

This site uses cookies to store information on your computer. By continuing to use our site, you consent to our cookies. If you are not happy with the use of these cookies, please review our Cookie Policy to learn how they can be disabled. By disabling cookies, some features of the site will not work.