Install Pop CLI
Quick install (macOS/Linux with Homebrew)
brew install r0gue-io/pop-cli/popNeed Homebrew? Follow Install Homebrew.
Other install options
Using cargo-binstall (cross-platform, downloads pre-built binaries when available):
# Install cargo-binstall if you don't have it
curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
# Install pop-cli
cargo binstall pop-cli --lockedUsing Ubuntu PPA:
sudo add-apt-repository ppa:r0gue-io/pop
sudo apt-get update
sudo apt-get install pop-cliIf
add-apt-repositoryis not found, install it withsudo apt-get install software-properties-common.
Debian/Ubuntu (using .deb package from GitHub Releases):
sudo dpkg -i pop-cli_*.debNix/NixOS:
Arch Linux (using pacman with a .pkg.tar.zst from GitHub Releases):
1. Install Pop CLI
1.1 For macOS and Linux (Homebrew)
Install Homebrew (if not installed)
Run the official installer (more info here):
Add Homebrew to your PATH (if the installer didn’t do it for you):
macOS (Apple Silicon):
Linux:
Verify:
Install Pop CLI with Homebrew:
1.2 Build from source (any OS)
Firstly, install Rust:
And now build pop-cli from source and install it:
2. Set up your environment
Recommended next step: Run
pop installto set up OS packages, Rust tooling, and optional frontend dependencies.
Warning:
pop installmay download and run external scripts when dependencies are missing, including the official installers for Homebrew, rustup, nvm, and Bun.
Install command flags
-y, --skip-confirm
Skip confirmation prompts and install everything non-interactively.
-f, --frontend
Install frontend dependencies (Node.js v20+ and Bun).
JSON mode
Use global --json for structured automation output:
JSON mode notes:
pop --json installrequires-y/--skip-confirm.pop --json completionrequires a shell via positionalSHELLor--shell.
Interactive prompts
By default, pop install prompts you before installing OS packages and frontend dependencies. Use -y to skip all prompts.
Rust toolchain setup
pop install installs or updates rustup, then:
Sets the default toolchain to
stableUpdates Rust
Adds the
wasm32-unknown-unknowntargetInstalls components:
cargo,clippy,rust-analyzer,rust-src,rust-std,rustc,rustfmt
Compatibility notes: Pop CLI targets ink! v6 by default in the latest releases. If you need ink! v5 support, install version
0.10.0:
Installing frontend dependencies
If you plan to use frontend templates with your chains or contracts, you can install the required frontend dependencies:
This will install:
Node.js (v20+) via
nvmif your currentnode --versioncheck fails or is too oldBun (required for certain frontend templates like inkathon)
If Bun installs successfully but is not on your PATH yet, Pop CLI checks the default location at ~/.bun/bin/bun.
These dependencies are automatically checked when you use the --with-frontend flag with pop new chain or pop new contract.
Set up shell completion
Use pop completion to generate shell completion scripts for Bash, Zsh, Fish, PowerShell, or Elvish.
Usage
Arguments and flags
SHELL
Optional positional shell (bash, zsh, fish, powershell, elvish). Mutually exclusive with --shell.
--shell <SHELL>
Shell to generate completions for (same values as SHELL).
-o, --output <PATH>
Write the completion script to a file instead of stdout.
Behavior and defaults
If you omit
--output, Pop writes the completion script to stdout.If you pass
--output, Pop writes the file and prints post-install steps for the selected shell.If you pass
--outputwithout a shell, Pop tries to detect the shell from$SHELL. If it detects one, it uses that shell and continues. If it cannot detect one and stdin is a TTY, it falls back to interactive setup. If stdin is not a TTY, it returns an error.In interactive setup, Pop asks you to choose a shell, suggests a default output path, and confirms before writing the file.
Default output paths (interactive)
bash
~/.local/share/bash-completion/completions/pop
zsh
~/.zsh/completions/_pop
fish
~/.config/fish/completions/pop.fish
powershell
~/.config/powershell/Completions/pop.ps1
elvish
~/.config/elvish/lib/pop.elv
Post-install steps by shell
bash
Source the file once, add source <PATH> to ~/.bashrc, then restart your shell.
zsh
Add the completion directory (the parent of the output file) to fpath, run autoload -Uz compinit && compinit, then restart your shell.
fish
Restart your shell; Fish auto-loads completions from the standard completions directory.
powershell
Ensure your PowerShell profile loads the completion file, then restart your shell.
elvish
Ensure your Elvish config loads the completion file, then restart your shell.
Examples
Errors and constraints
--outputrequires a shell if$SHELLis not set and stdin is not a TTY.The output path cannot be empty.
Interactive setup requires a resolved home directory.
3. Advanced details
OS packages and behavior
If your OS/distro is unsupported, pop install prints a warning and exits without installing OS packages or tooling.
macOS
Homebrew
homebrew, protobuf, openssl, cmake, rustup
Arch (or compatible)
pacman
curl, git, clang, make, protobuf, rustup
Ubuntu (or compatible)
apt
git, clang, curl, libssl-dev, protobuf-compiler, lsof, pkg-config, rustup
Debian (or compatible)
apt
git, clang, curl, libssl-dev, llvm, libudev-dev, make, protobuf-compiler, lsof, rustup
Red Hat (or compatible)
yum
gcc, gcc-c++, make, cmake, pkgconf, pkgconf-pkg-config, clang, curl, git, openssl-devel, protobuf-compiler, lsof, rustup
When you pass --frontend, pop install also installs unzip on Arch, Ubuntu, and Debian. Need help?
Ask on Polkadot Stack Exchange (tag it pop) or drop by our Telegram. We're here to help!
Last updated