GoogleCloudPlatform/cloud-sql-proxy

Secure local tunnel to Cloud SQL

What

Local proxy that opens an IAM-authenticated, encrypted connection to a Cloud SQL instance, so you connect to 127.0.0.1 without allowlisting IPs.

How to use

bash
# download the binary for your OS from the README/Releases, then:
./cloud-sql-proxy <PROJECT:REGION:INSTANCE>
# connect your client to 127.0.0.1 on the DB's usual port

Reach for it when

connecting to Cloud SQL from a laptop or a non-GCP host.