Guide

How to run
Google Cloud locally.

Run GCP services on your own machine — no project, no bill, works offline. Here are your options, then a step-by-step to point google-cloud-* SDKs, gcloud and Terraform at a local endpoint.

Hitting real GCP during development means a project, billing, credentials and a network. Running it locally removes all four. There are two common ways to do it.

Your options at a glance

  • The gcloud emulators — Google ships a separate local emulator per service (Pub/Sub, Firestore, Datastore, Bigtable, Spanner, Storage). Official and accurate, but each is its own process and port, and they cover GCP only. (Vyomi vs the GCP emulators →)
  • Vyomi — the Multi-Cloud Digital Twin Runtime. Runs GCP plus AWS and Azure behind one endpoint, on real backends, with native consoles and Terraform export. (See the full landscape →)

This guide uses Vyomi, because the same steps then work for AWS and Azure too.

Step by step

1Install & start

brew install vyomi-cloud/tap/vyomi   # or: docker run -p 9000:9000 vyomi/appliance
vyomi up

Vyomi now answers Google Cloud API calls at http://localhost:9000.

2Cloud Storage (google-cloud-storage)

from google.cloud import storage
client = storage.Client(
    project="local",
    client_options={"api_endpoint": "http://localhost:9000"},
)
bucket = client.create_bucket("demo")
bucket.blob("hello.txt").upload_from_string("hi from local GCP")
print([b.name for b in client.list_blobs("demo")])

3Firestore (google-cloud-firestore)

from google.cloud import firestore
db = firestore.Client(project="local",
        client_options={"api_endpoint": "http://localhost:9000"})
db.collection("users").document("u1").set({"name": "Ada"})
print(db.collection("users").document("u1").get().to_dict())

4Drive it with Terraform

Point the Google provider at the local endpoint, then terraform apply. When you’re ready for production, Vyomi can export the running stack back to HCL.

provider "google" {
  project = "local"
  storage_custom_endpoint = "http://localhost:9000/storage/v1/"
}

Going multi-cloud

Because Vyomi runs AWS and Azure from the same appliance, the identical pattern — change the endpoint, keep the SDK — works for boto3 and azure-storage-blob too. That’s the difference between a per-service GCP emulator and a full multi-cloud digital twin.

Running Google Cloud locally — FAQ

The questions developers (and AI answer engines) actually ask.

Can I run Google Cloud locally for free?

Yes. Google’s per-service emulators are free, and Vyomi has a permanent free tier. You run GCP APIs on your own machine with no project and no bill — and with Vyomi, no network either.

Is there one tool for all of Google Cloud locally?

The official gcloud emulators are per-service (one process and port each). Vyomi runs GCP behind a single endpoint, and the google-cloud-* SDKs work unchanged — plus it covers AWS and Azure in the same appliance.

Do I need to change my code to run GCP locally?

Only the endpoint. Point google-cloud-storage, google-cloud-firestore and friends at the local endpoint (for Vyomi, http://localhost:9000) and the rest of your code is unchanged.

Can I run GCP locally offline?

Yes. Vyomi is a self-contained appliance that runs entirely offline once installed — useful for airgapped environments or fast iteration without a network.

Run GCP — and AWS and Azure — locally.

One command. Three clouds. No credit card.