Hide
Cloud SDK

Google Cloud SDK contains tools and libraries that enable you to easily create and manage resources on Google Cloud Platform, including App Engine, Compute Engine, Cloud Storage, BigQuery, Cloud SQL, and Cloud DNS.

Installation and Quick Start

Linux/Mac OS X
  1. Download and install Google Cloud SDK by running the following command in your shell or Terminal:

    curl https://sdk.cloud.google.com | bash

    (Or, you can download google-cloud-sdk.zip or google-cloud-sdk.tar.gz, unpack it, and launch the ./google-cloud-sdk/install.sh script.)

  2. Restart your shell:

    exec -l $SHELL
  3. Authenticate to Google Cloud Platform by running gcloud auth login.

Note: You can use export CLOUDSDK_CORE_DISABLE_PROMPTS=1 to perform a silent installation.

Windows

Download the Google Cloud SDK installer for Windows

  1. Launch the downloaded GoogleCloudSDKInstaller.exe installer and follow the prompts.

  2. When the installation finishes, open a command prompt (cmd.exe) or the Google Cloud SDK Shell from Desktop or Start Menu.

  3. Authenticate to Google Cloud Platform by running gcloud auth login.

Alternative methods

Here are the alternative methods for installing Google Cloud SDK.

Install a specific Cloud SDK version

If necessary, it is possible to install previous versions of the Cloud SDK. You can do this either with a fresh installation, or by updating an existing installation to a previous version. In the following examples VERSION is the version number of the Cloud SDK you want to install (like 0.9.66).

  1. If doing a fresh install:

    export CLOUDSDK_COMPONENT_MANAGER_FIXED_SDK_VERSION=VERSION
    curl https://sdk.cloud.google.com | bash
  2. If you have an existing installation:

    export CLOUDSDK_COMPONENT_MANAGER_FIXED_SDK_VERSION=VERSION
    gcloud components update
  3. If you want to make that setting persistent (to prevent accidental upgrades):

    gcloud config set --scope=installation component_manager/fixed_sdk_version VERSION

Installation on Windows using Cygwin

  1. Download and install a 32-bit version of Cygwin, following Cygwin's installation instructions. While installing Cygwin, be sure to select openssh, curl and the latest 2.7.x version of python from the package selection screen.

  2. Launch Cygwin from Start → All Programs → Cygwin → Cygwin Terminal.

  3. Download and install Google Cloud SDK by running the following command in your Cygwin Terminal:

    curl https://sdk.cloud.google.com | bash

    (Or, you can download google-cloud-sdk.zip or google-cloud-sdk.tar.gz, unpack it, and launch the ./google-cloud-sdk/install.sh script.)

  4. Restart Cygwin Terminal, and authenticate to Google Cloud Platform by running gcloud auth login.

Installation from an archive (.zip) on Windows

  1. Download google-cloud-sdk.zip and extract the contents (right-click the file and choose "Extract All...").

  2. Launch the google-cloud-sdk\install.bat script and follow the installation prompts.

  3. When the installation finishes, restart the command prompt ( cmd.exe) and authenticate to Google Cloud Platform by running gcloud auth login.

Installation from a base Docker image

  1. Get the Google Cloud SDK Docker image:

    $ docker pull google/cloud-sdk

  2. Authenticate to Google Cloud Platform and save the OAuth 2.0 credentials in gcloud-config volume.

    $ docker run -t -i --name gcloud-config google/cloud-sdk gcloud auth login
    
    Go to the following link in your browser: ...
    Enter verification code: ...

  3. Re-use the credentials from gcloud-config volume when running gcloud commands.

    $ docker run -t -i --volumes-from gcloud-config google/cloud-sdk gcloud compute instances list

For more information see "google/cloud-sdk" Docker image documentation.

Getting Started

Step 1. Install Cloud SDK

If you have not already installed the Cloud SDK and authenticated, do so by following the steps in the Quick Start above.

Step 2. Get started with a Google Cloud Platform service

With the Cloud SDK command-line interface, you can easily manage your service resources and your development workflow.

Step 3. Submit questions and give us feedback

Have a question? Ask on StackOverflow using the "gcloud" tag or check out our groups page.

Found a bug? File it in our issue tracker site. Any feedback is appreciated!

Learn more

gcloud Tool Guide
Learn more about gcloud, Cloud SDK command-line tool to manage your development workflow.
Cloud Platform Tools
Learn about App Engine, Compute, Storage, BigQuery and Cloud SQL tools, bundled with Cloud SDK.
Cloud Platform Solutions
See how you can quickly and easily build a mobile, gaming, or Hadoop solution.