This page describes how to get started with the
gcloud CLI
so you can use it to manage Cloud SQL instances. The gcloud CLI
uses the Cloud SQL Admin API to access Cloud SQL, so you must enable the API before you
can use the gcloud CLI to access Cloud SQL.
For gcloud examples, see the
How-to page for the task.
Getting started with the gcloud CLI
To start with the gcloud CLI, review the
gcloud CLI Documentation.
You can get help for the tool, resources, and
commands by using the --help flag:
The help displayed with the --help flag is also available in
the gcloud CLI reference for
gcloud sql.
Finally, configure a project as your default project with
two commands. The first command below lists the
configuration for the gcloud CLI, including any default project
already set. The second command sets the default project.
[[["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-28 UTC."],[],[],null,["# About the gcloud CLI\n\n\u003cbr /\u003e\n\nMySQL \\| [PostgreSQL](/sql/docs/postgres/cloud-sdk \"View this page for the PostgreSQL database engine\") \\| [SQL Server](/sql/docs/sqlserver/cloud-sdk \"View this page for the SQL Server database engine\")\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\nThis page describes how to get started with the\n[gcloud CLI](/sdk/docs)\nso you can use it to manage Cloud SQL instances. The gcloud CLI\nuses the Cloud SQL Admin API to access Cloud SQL, so you must enable the API before you\ncan use the gcloud CLI to access Cloud SQL.\n\nFor `gcloud` examples, see the\n[How-to page](/sql/docs/mysql/how-to) for the task.\n\nGetting started with the gcloud CLI\n-----------------------------------\n\nTo start with the gcloud CLI, review the\n[](/sdk/docs)[gcloud CLI](/sdk/gcloud) Documentation.\nYou can get help for the tool, resources, and\ncommands by using the `--help` flag: \n\n```bash\ngcloud sql --help\ngcloud sql instances --help\ngcloud sql instances create --help\n```\n\nThe help displayed with the `--help` flag is also available in\nthe [gcloud CLI](/sdk/gcloud) reference for\n[gcloud sql](/sdk/gcloud/reference/sql).\n\n\nFinally, configure a project as your default project with\ntwo commands. The first command below lists the\nconfiguration for the gcloud CLI, including any default project\nalready set. The second command sets the default project. \n\n```bash\ngcloud config list\ngcloud config set project [PROJECT_ID]\n```"]]