Command Line

The Heroku Command Line Interface (CLI), formerly known as the Heroku Toolbelt, is a tool for creating and managing Heroku apps from the command line / shell of various operating systems.


  • $ heroku –version
  • $ heroku login
  • $ heroku create

Download and install


Download and run the OS X installer.


Download and run the Windows installer 32-bit 64-bit.


Run the following to add our apt repository and install the CLI:

$ sudo add-apt-repository "deb ./"
$ curl -L | sudo apt-key add -
$ sudo apt-get update
$ sudo apt-get install heroku

Standalone version

Download the tarball and extract it so that you can access the binary from your PATH. For example:

$ echo replace OS/ARCH with values as noted below
$ wget
$ tar -xvzf heroku-OS-ARCH /usr/local/lib/heroku
$ ln -s /usr/local/lib/heroku/bin/heroku /usr/local/bin/heroku

Verify your installation

To verify your CLI installation use the heroku --version command.

$ heroku --version
heroku-cli/5.6.0-010a227 (darwin-amd64) go1.7.4

Getting started

You will be asked to enter your Heroku credentials the first time you run a command; after the first time, your email address and an API token will be saved to ~/.netrc for future use.

It’s generally a good idea to login and add your public key immediately after installing the Heroku CLI so that you can use git to push or clone Heroku app repositories:

$ heroku login
Enter your Heroku credentials.
Email: [email protected]
Password (typing will be hidden):
Authentication successful.

You’re now ready to create your first Heroku app:

$ cd ~/myapp
$ heroku create
Creating app... done, ⬢ sleepy-meadow-81798 |