Stay organized with collections
Save and categorize content based on your preferences.
This document describes how to set up a Google Cloud project and a
Compute Engine virtual machine (VM).
Set up a Google Cloud project
Sign in to your Google Cloud account. 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.
In the Google Cloud console, on the project selector page,
select or create a Google Cloud project.
To initialize the gcloud CLI, run the following command:
gcloudinit
Do you Need Credentials? You need credentials only if
you plan to directly call Dataproc APIs from your application or from
a browser. If you plan on using the Google Cloud console or the
Google Cloud CLI to
create and manage clusters and to submit jobs, you only need to be logged in
to the SDK with the gcloud init command.
Optional: Set up a VM
If you plan to run gcloud CLI from a
Compute Engine virtual machine (VM) instance, the VM must be set up
to access Google Cloud services.
To test whether your VM is set up correctly, run
gcloud compute instances describe YOUR_VM_INSTANCE_NAME
from the command line. A service account must be listed that includes the
https://www.googleapis.com/auth/cloud-platform scope. For more information
on setting up a VM, see
Create a VM that uses a user-managed service account.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-25 UTC."],[[["\u003cp\u003eThis document provides instructions on setting up a Google Cloud project and a Compute Engine virtual machine (VM).\u003c/p\u003e\n"],["\u003cp\u003eCredentials are only necessary when directly calling Dataproc APIs from an application or browser, not when using the Google Cloud console or the gcloud CLI.\u003c/p\u003e\n"],["\u003cp\u003eIf utilizing a Compute Engine VM to run gcloud CLI, it must be configured to access Google Cloud services, with a service account that includes the \u003ccode\u003ehttps://www.googleapis.com/auth/cloud-platform\u003c/code\u003e scope.\u003c/p\u003e\n"],["\u003cp\u003eCloud Shell can be used as an alternative to setting up a personal VM, as it automatically provisions a VM with the necessary scopes to run gcloud CLI commands.\u003c/p\u003e\n"]]],[],null,["# Set up a project\n\nThis document describes how to set up a Google Cloud project and a\nCompute Engine virtual machine (VM).\n\nSet up a Google Cloud project\n-----------------------------\n\n- Sign in to your Google Cloud account. If you're new to Google Cloud, [create an account](https://console.cloud.google.com/freetrial) to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.\n- In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n | **Note**: If you don't plan to keep the resources that you create in this procedure, create a project instead of selecting an existing project. After you finish these steps, you can delete the project, removing all resources associated with the project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n-\n [Verify that billing is enabled for your Google Cloud project](/billing/docs/how-to/verify-billing-enabled#confirm_billing_is_enabled_on_a_project).\n\n-\n\n\n Enable the Google Cloud Dataproc API.\n\n\n [Enable the API](https://console.cloud.google.com/flows/enableapi?apiid=dataproc)\n-\n [Install](/sdk/docs/install) the Google Cloud CLI.\n\n- If you're using an external identity provider (IdP), you must first\n [sign in to the gcloud CLI with your federated identity](/iam/docs/workforce-log-in-gcloud).\n\n-\n To [initialize](/sdk/docs/initializing) the gcloud CLI, run the following command:\n\n ```bash\n gcloud init\n ```\n\n- In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n | **Note**: If you don't plan to keep the resources that you create in this procedure, create a project instead of selecting an existing project. After you finish these steps, you can delete the project, removing all resources associated with the project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n-\n [Verify that billing is enabled for your Google Cloud project](/billing/docs/how-to/verify-billing-enabled#confirm_billing_is_enabled_on_a_project).\n\n-\n\n\n Enable the Google Cloud Dataproc API.\n\n\n [Enable the API](https://console.cloud.google.com/flows/enableapi?apiid=dataproc)\n-\n [Install](/sdk/docs/install) the Google Cloud CLI.\n\n- If you're using an external identity provider (IdP), you must first\n [sign in to the gcloud CLI with your federated identity](/iam/docs/workforce-log-in-gcloud).\n\n-\n To [initialize](/sdk/docs/initializing) the gcloud CLI, run the following command:\n\n ```bash\n gcloud init\n ```\n\n\u003cbr /\u003e\n\n| **Note:** When you enable the Dataproc API, the Dataproc Control API is also enabled. Disabling the Dataproc API doesn't disable the Dataproc Control API. You must separately disable the Dataproc Control API.\n\n**Do you Need Credentials?** You need credentials only if\nyou plan to directly call Dataproc APIs from your application or from\na browser. If you plan on using the Google Cloud console or the\n[Google Cloud CLI](/sdk/gcloud/reference/dataproc) to\ncreate and manage clusters and to submit jobs, you only need to be logged in\nto the SDK with the `gcloud init` command.\n\nOptional: Set up a VM\n---------------------\n\nIf you plan to run [gcloud CLI](/sdk/docs) from a\nCompute Engine virtual machine (VM) instance, the VM must be set up\nto access Google Cloud services.\n\nTo test whether your VM is set up correctly, run\n`gcloud compute instances describe `\u003cvar translate=\"no\"\u003eYOUR_VM_INSTANCE_NAME\u003c/var\u003e\nfrom the command line. A service account must be listed that includes the\n`https://www.googleapis.com/auth/cloud-platform` scope. For more information\non setting up a VM, see\n[Create a VM that uses a user-managed service account](/compute/docs/access/create-enable-service-accounts-for-instances).\n| **Use Cloud Shell to run\n| gcloud CLI commands.** As an alternative to setting up your own VM to run SDK commands, open a [Cloud Shell](/shell/docs/quickstart) session to automatically provision a VM with the necessary scopes, and then run gcloud CLI commands from Cloud Shell.\n\n*** ** * ** ***\n\n[Next Step: Create a Cluster](/dataproc/docs/guides/create-cluster)"]]