Skip to content

Install the Aptos CLI on Mac

For Mac, the easiest way to install the Aptos CLI is with the package manager brew.

  1. Ensure you have brew installed https://brew.sh/.

  2. Open a new terminal and enter the following commands.

    Terminal window
    brew update
    brew install aptos
  3. Open another terminal and run aptos help to verify the CLI is installed.

    Terminal window
    aptos help

Upgrading the CLI with brew just takes 2 commands:

Terminal window
brew update
brew upgrade aptos
  1. In the terminal, use one of the following commands:

    Terminal window
    curl -fsSL "https://aptos.dev/scripts/install_cli.sh" | sh

    Or use the equivalent wget command:

    Terminal window
    wget -qO- "https://aptos.dev/scripts/install_cli.sh" | sh
  2. (Optional) It can be helpful to add the Aptos CLI to a folder in your PATH, or to add it to your PATH directly.

    • The steps to add a folder to your PATH are shell dependent.
    • You can run echo $SHELL to print the default shell for your machine, then google specific steps to add a folder to your PATH for that shell.
  3. Verify the script is installed by opening a new terminal and running aptos help

    • You should see a list of commands you can run using the CLI.
    • In the future, this is a helpful resource to learn exactly how each command works.

Install via Pre-Compiled Binaries (Backup Method)

Section titled “Install via Pre-Compiled Binaries (Backup Method)”
  1. Go to the .

  2. Click the “Assets” expandable menu for the latest release to see the pre-compiled binaries.

  3. Download the zip file for macOS.

    1. It’ll have a name like: aptos-cli-<version>-macOS-x86_64.zip or aptos-cli-<version>-macOS-arm64.zip.
    2. Make sure you choose the right zip file for your computer architecture (x86_64 for Intel / AMD or arm64 for ARM).
    3. You will likely have to dismiss warnings that this is a suspicious file when downloading.
  4. Unzip the downloaded file.

  5. Move the extracted Aptos binary file into your preferred folder.

  6. Open a terminal and navigate to your preferred folder.

  7. Make ~/aptos an executable by running chmod +x ~/aptos.

  8. Verify that this installed version works by running ~/aptos help.

    You should see instructions for how to use all CLI commands. These can be helpful in the future when you are trying to understand how to use specific commands.

  9. (Optional) It can be helpful to add the Aptos CLI to a folder in your PATH, or to add it to your PATH directly.

    • The steps to add a folder to your PATH are shell dependent.
    • You can run echo $SHELL to print the default shell for your machine, then google specific steps to add a folder to your PATH for that shell.