Skip to main content
Google Cloud

Hosting WordPress on Google Cloud: Compute Engine, Cloud Run, or Managed Hosting

Compare ways to host WordPress on Google Cloud: a Compute Engine VM, Cloud Run with Cloud SQL, GKE, or managed hosting, with costs, effort, and backups.

Last checked against Google's official documentation on .

Hosting WordPress on Google Cloud: Compute Engine, Cloud Run, or Managed Hosting

WordPress still powers a large share of the web, and Google Cloud is a perfectly good place to run it. The hard part is choosing how. Google itself suggests three different architectures, and there is a fourth path, managed hosting on Google Cloud infrastructure, that suits many companies better than any of them.

This guide compares the options on cost, effort, performance, and security, so an IT admin can make a decision without reading five tutorials. If your company already uses Google Workspace, you can keep the website in the same Google Cloud organization and protect its admin pages with the same sign-in.

Key Takeaways

  • Compute Engine VM from Marketplace: fastest to launch, you manage everything.
  • Cloud Run with Cloud SQL: scales with traffic, more moving parts.
  • GKE with Cloud SQL: for teams already running Kubernetes.
  • Managed hosting on Google Cloud: least effort for typical business sites.
  • Whatever you choose, plan backups, updates, and admin access from day one.

Table of contents

Open Table of contents

The Options at a Glance

WordPress hosting options on Google Cloud compared

OptionEffortScalingTypical monthly costBest for
Compute Engine VM (Marketplace)MediumManual, one VMLowSmall to medium sites, full control
Cloud Run and Cloud SQLHigh at setup, lower to runAutomaticMediumSpiky traffic, container-friendly teams
GKE and Cloud SQLHighAutomaticMedium to highTeams already on Kubernetes
Managed WordPress hostLowHandled by hostVaries by planMost business sites and blogs

Google’s WordPress page describes the first three and quotes hosting from USD 13.17 a month, without saying which setup that figure covers. Use the pricing calculator with your own traffic before deciding.

Option 1: A Compute Engine VM

The Marketplace listing deploys a VM with WordPress, a web server, and MySQL already installed. Google calls it the fastest way to deploy.

What you get: a single VM you can SSH into and configure fully.

What you manage: operating system updates, WordPress and plugin updates, the database on the same VM, backups, TLS certificates, and security hardening.

Good practice:

  • Choose a small machine type to start; WordPress with caching runs comfortably on modest VMs.
  • Schedule persistent disk snapshots daily.
  • Use a static external IP and put Cloudflare or Cloud CDN in front for caching.
  • Close SSH to the internet and use IAP TCP forwarding instead.

Note that Free Trial billing accounts cannot use Marketplace, according to Google’s free trial documentation. You can install WordPress on a plain VM yourself during the trial, or upgrade first. Our free tier guide lists the other trial limits.

Option 2: Cloud Run with Cloud SQL

Google’s WordPress page lists a serverless option on Cloud Run, which needs a MySQL database alongside it, usually Cloud SQL for MySQL. Google suggests it for variable traffic with high peaks.

How it works: WordPress runs in a container that scales with traffic, the database lives in Cloud SQL, and uploaded media goes to a Cloud Storage bucket through a plugin or a mounted volume, because containers do not keep files between restarts.

Trade-offs:

  • Cloud SQL runs all the time, so the floor cost is the database, not the containers.
  • Plugin installs and updates need a rebuild of the container image, which changes how editors work.
  • Cold starts can slow the first request; set a minimum instance count of one for a busy site.

This is a strong option for a team comfortable with containers, and a frustrating one for a marketing team that expects to install plugins from the dashboard. Our Cloud Run guide covers the basics.

Option 3: GKE with Cloud SQL

Google also lists WordPress on Google Kubernetes Engine with Cloud SQL for MySQL, and its WordPress page labels this the recommended option for easy-to-manage sites with minimal management overhead. In practice, it makes the most sense if you already run GKE and want WordPress to follow the same deployment, monitoring, and security practices. For a single marketing site, it is far more platform than you need.

Option 4: Managed Hosting on Google Cloud

Several managed WordPress hosts run their platforms on Google Cloud infrastructure. You get Google’s network and data centers without managing servers. The host handles updates, caching, staging sites, backups, and malware scanning, and usually offers support that understands WordPress.

The trade-off is control. The site lives in the host’s account, not your Google Cloud organization, so your IAM, organization policies, and audit logs do not apply. For most business websites and blogs, that is an acceptable trade for far less work.

Security Essentials for Any Option

  • Updates: WordPress core, themes, and plugins, ideally automatic for minor releases.
  • Admin access: protect /wp-admin with strong passwords and two-factor sign-in, or put it behind IAP for staff-only access on self-managed setups.
  • Least plugins: every plugin is code you are trusting.
  • Web application firewall: Cloud Armor on a load balancer, or your CDN’s WAF.
  • Posture checks: on self-managed setups, review Security Command Center findings for the project, such as open firewall rules and public buckets.
  • Database: never expose MySQL to the internet; use private IP for Cloud SQL.

Backups

OptionWhat to back upHow
Compute Engine VMWhole diskScheduled snapshots, plus an off-VM database dump
Cloud Run or GKEDatabase and media bucketCloud SQL automated backups, bucket versioning or soft delete
Managed hostUsually includedConfirm retention and test a restore

Store at least one backup copy outside the hosting setup, for example in a Cloud Storage bucket with lifecycle rules as described in our storage classes guide.

How to Choose

  • A company blog or brochure site with a small team: managed hosting.
  • A site that must live in your Google Cloud organization, with an admin to run it: Compute Engine VM.
  • A high-traffic or campaign site with a container-savvy team: Cloud Run and Cloud SQL.
  • An organization standardized on Kubernetes: GKE.

Step by Step: The Compute Engine Option

For admins who choose the VM route, a dependable setup looks like this:

  1. Create a project in your Production folder, linked to the company billing account, with a budget.
  2. Deploy WordPress from the Marketplace listing, or create an Ubuntu or Debian VM and install a web server, PHP, and MySQL or MariaDB yourself.
  3. Pick a region close to readers, such as asia-south1 for an Indian audience.
  4. Reserve a static external IP and point your domain’s A record at it.
  5. Install a TLS certificate, for example with Let’s Encrypt, or terminate TLS at a CDN or load balancer.
  6. Turn on automatic updates for the OS and minor WordPress releases.
  7. Schedule daily snapshots of the boot disk and a nightly database dump to a Cloud Storage bucket.
  8. Close SSH to the internet and use IAP for admin access.
  9. Add a caching plugin and a CDN.

Performance Tips

  • Cache aggressively. Page caching and a CDN do more for speed than a bigger VM.
  • Optimize images before upload, or use a plugin that serves modern formats.
  • Limit plugins, especially those that run on every page load.
  • Use PHP’s opcode cache and a current PHP version.
  • Move the database to Cloud SQL when traffic grows, so web servers can scale separately.
  • Monitor with Cloud Monitoring uptime checks and alert on downtime.

Migrating an Existing WordPress Site

Moving a live site from shared hosting to Google Cloud follows the same steps whatever the target:

  1. Back up the current site: files (especially wp-content) and a database export.
  2. Build the new environment and restore the files and database there.
  3. Update configuration: database credentials in wp-config.php, and the site URL if testing on a temporary address.
  4. Test thoroughly on a temporary hostname or by editing your local hosts file: logins, forms, images, checkout if there is one.
  5. Lower the DNS TTL a day before the move.
  6. Freeze changes on the old site, take a final database export, and import it.
  7. Switch DNS to the new environment.
  8. Keep the old host running for a week in case you need to roll back.

Migration plugins can automate the file and database steps, but test the result before switching DNS. Keep your email records untouched during the move; changing the A record does not affect Workspace mail as long as MX, SPF, DKIM, and DMARC stay the same.

Conclusion

There is no single best way to run WordPress on Google Cloud, only the best fit for the people who will look after it. Pick the option that matches your team’s skills, budget for backups and updates, and protect the admin pages.

Whichever you choose, keep the domain’s DNS and email records tidy alongside your Google Workspace setup; our Cloud DNS guide shows how. The final two guides in this series cover Google Cloud certifications, starting tomorrow with Cloud Digital Leader.


Official Google documentation:

Related reading:

This guide contains referral or affiliate links. If you sign up through one, Workspace Blog may earn a commission at no extra cost to you. Read our referral and advertising disclosure.

Frequently Asked Questions

What is the easiest way to run WordPress on Google Cloud?
The fastest option is the WordPress listing in Google Cloud Marketplace, which deploys a ready-made WordPress VM on Compute Engine with one click. You then manage that VM yourself, including updates, backups, and security.
Can WordPress run on Cloud Run?
Yes. Google's WordPress page lists a serverless Cloud Run option and suggests it for sites with variable traffic and high peaks. WordPress still needs a MySQL database, usually Cloud SQL for MySQL. Because Cloud Run containers are stateless, uploaded media must be stored outside the container, typically in Cloud Storage.
How much does WordPress on Google Cloud cost?
It depends on the option. Google's WordPress page mentions hosting starting at USD 13.17 a month after the free trial, without saying which setup that covers. A small VM on Compute Engine is usually the cheapest self-managed option, while Cloud Run with Cloud SQL costs more because the database runs all the time.
Can I host WordPress on the Google Cloud free trial?
You can use the $300 free trial credit for Compute Engine and Cloud SQL, but Google's free trial documentation says Free Trial billing accounts cannot use Google Cloud Marketplace. To use the one-click Marketplace listing, you need to upgrade to a paid account first.
Is managed WordPress hosting better than running it myself?
For most small businesses and blogs, yes. A managed host handles updates, caching, backups, and security, and several run on Google Cloud infrastructure. Self-managing on Google Cloud makes sense when you need control, have in-house skills, or must keep the site inside your own cloud organization.