Installing from versioned archives

The gcloud CLI provides downloadable, versioned archives for each release. Each versioned archive contains a self-contained installation of the gcloud CLI in a directory named google-cloud-sdk that can be copied to any location on your file system.

Best uses for installing from versioned archives

Versioned archives are designed for non-interactive installation of specific versions of the gcloud CLI and are useful when:

  • You require a specific version of the gcloud CLI. For example:

    • You're scripting with the gcloud CLI or another gcloud CLI component and want to make sure that your scripts don't break as the result of a gcloud CLI update.
    • You're using the gcloud CLI as part of a CI (continuous integration) process or production system where you want to control your dependencies in order to ensure compatibility between parts of the system.
    • You're performing automated deployments of the gcloud CLI to many machines that must be in sync.
    • You're behind a proxy or firewall that requires additional configuration to be able to access the internet.
  • You don't want to perform an interactive installation.

Installation instructions

To install the latest release of the gcloud CLI from a versioned archive:

  1. Check which version (64-bit or 32-bit) your OS is running on.

    • Linux / macOS: Run getconf LONG_BIT from your command line
    • Windows: Control Panel > System > System Type

    Additionally, for macOS, to check your machine hardware name (x86_64, arm64, or x86), run uname -m.

  2. Download the appropriate archive compatible with your version:

    Platform Package Size SHA256 Checksum
    Linux 64-bit

    (x86_64)

    google-cloud-cli-linux-x86_64.tar.gz 88.5 MB 1c478abfe0fbe256b8ecaba2faeff154e44c308064b1c69d9ec15b879a4944bd
    Linux 64-bit

    (Arm)

    google-cloud-cli-linux-arm.tar.gz 61.3 MB ef8ded3afd45c89bc3900e32579bddfa406b44f7837d993adac417f00b41aa8f
    Linux 32-bit

    (x86)

    google-cloud-cli-linux-x86.tar.gz 61.4 MB 52164ff332756c784df60ffcca7f6fd89c5465431b2019cbcd117631b76898c2
    macOS 64-bit

    (x86_64)

    google-cloud-cli-darwin-x86_64.tar.gz 61.5 MB c755c6ed2deb167c7d7a96909739e8faed855b728f3496e7e57d139243699b0c
    macOS 64-bit

    (arm64)

    google-cloud-cli-darwin-arm.tar.gz 61.4 MB 99b96b1f78ed4e7e925a1f6f1b55191e3f77cdc811ba0f907c62c19fc58caa10
    macOS 32-bit

    (x86)

    google-cloud-cli-darwin-x86.tar.gz 59.9 MB dd1f6d136d27fde99ff1eb92d37e09985b2e2c7547bf93556e1c121c68310524
    Windows 64-bit

    (x86_64)

    google-cloud-cli-windows-x86_64.zip 84.5 MB 21e68c5e1a88ee4abb484719500c925f814695d8300a7a88db53c70df2d2f142
    Windows 64-bit

    (x86_64) with Python bundled

    google-cloud-sdk-577.0.0-windows-x86_64-bundled-python.zip 110.8 MB dcf9097b2c7a0a29bd6322571f5090c6046bed96b19c0750e62f549b735b80eb
    Windows 32-bit

    (x86)

    google-cloud-cli-windows-x86.zip 84.4 MB 3ba368f90194f5ff1ef0ad865e05adf4c9dd21f211c9ab4c52f4af0128a18b87
    Windows 32-bit

    (x86) with Python bundled

    google-cloud-sdk-577.0.0-windows-x86-bundled-python.zip 108.0 MB 2ba45053899025f3ff1142ed1fefea68d8c395d8831f6655f6f8d399e65fdb2e
  3. Extract the contents of the file to any location on your file system. Preferably, this is your Home folder.

  4. To add the gcloud CLI tools to your path, run the install script from the root of the folder you extracted. Running this script also generates instructions to enable command completion in your bash shell (Linux and macOS only) and enable usage reporting.

    • On Linux or macOS:

      ./google-cloud-sdk/install.sh
      

      To run the install script with screen reader mode turned on:

      ./google-cloud-sdk/install.sh --screen-reader=true
      
    • On Windows:

      .\google-cloud-sdk\install.bat
      

    Run install.sh --help or install.bat --help for a list of flags you can pass to this script, including those that can run the installation non-interactively.

  5. To initialize the gcloud CLI, run gcloud init:

    • For Linux or macOS:

      ./google-cloud-sdk/bin/gcloud init
      
    • For Windows:

      .\google-cloud-sdk\bin\gcloud init
      

Previous versions

Previous versions of the gcloud CLI are available in the download archive in Cloud Storage. They are directly accessible through https://storage.googleapis.com/cloud-sdk-release/<archive_name>.

Try it for yourself

If you're new to Google Cloud, create an account to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.

Get started for free