Stay organized with collections
Save and categorize content based on your preferences.
MySQL is one of the most popular open source relational databases, offering
robust transaction processing at low costs. For a general overview of MySQL, see
What is MySQL.
There are several ways that you can deploy MySQL as part of your
Google Cloud project:
Cloud SQL offers MySQL as a web service. You can use Cloud SQL
to host your MySQL database in Google's cloud, and let Google Cloud handle
administrative duties like replication, patch management, and database
management. For an overview, see
Cloud SQL overview.
Google Cloud Marketplace lets you click to install MySQL onto a
Compute Engine instance. To browse available MySQL installation
options from Cloud Marketplace in the Google Cloud console:
Choose the best MySQL deployment option for your needs
To understand which MySQL deployment option best fits your needs, consider the
options as follows:
Try Cloud SQL (recommended)
If you want the convenience of having Google Cloud take care of the
backend database and server administration chores, we recommend that you use
Cloud SQL.
Cloud SQL provides the following advantages:
Automated backups
Point-in-time recovery
Replication of your data across multiple
zones for greater availability and
resiliency.
If you require MySQL features that Cloud SQL doesn't support, such as
user defined functions or the SUPER privilege, you can explore the options that
follow. For more information about the features that Cloud SQL
supports, see the
Cloud SQL FAQ.
Explore Google Cloud Marketplace deployment options
Cloud Marketplace offers several options for MySQL installations,
including:
A standalone MySQL installation
LAMP stacks
LEMP stacks
Nginx stacks
A Percona MySQL Cluster installation
Browse available MySQL installation options from Cloud Marketplace in
the Google Cloud console:
If the previous options don't fit your requirements, such as if you want to
deploy MySQL on a custom image you created, or if you want complete control of
the installation process, you can manually install MySQL by creating a
Compute Engine instance and installing MySQL directly onto it. For more
detailed instructions, see
Install MySQL on Compute Engine.
[[["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-26 UTC."],[],[],null,["# MySQL on Compute Engine\n\n*** ** * ** ***\n\nMySQL is one of the most popular open source relational databases, offering\nrobust transaction processing at low costs. For a general overview of MySQL, see\n[What is MySQL](/mysql).\n\nThere are several ways that you can deploy MySQL as part of your\nGoogle Cloud project:\n\n- *Cloud SQL* offers MySQL as a web service. You can use Cloud SQL to host your MySQL database in Google's cloud, and let Google Cloud handle administrative duties like replication, patch management, and database management. For an overview, see [Cloud SQL overview](/sql/docs/introduction).\n- *Google Cloud Marketplace* lets you click to install MySQL onto a\n Compute Engine instance. To browse available MySQL installation\n options from Cloud Marketplace in the Google Cloud console:\n\n [Go to Cloud Marketplace](https://console.cloud.google.com/marketplace/browse?q=mysql)\n- You can *manually install and customize* MySQL on Compute Engine. For\n manual installation instructions, see\n [Install MySQL on Compute Engine](/compute/docs/instances/mysql/setup-mysql). To optimize your configuration of\n MySQL, follow the guide at [Configure MySQL on Compute Engine]().\n\nChoose the best MySQL deployment option for your needs\n------------------------------------------------------\n\nTo understand which MySQL deployment option best fits your needs, consider the\noptions as follows:\n\n### Try Cloud SQL (recommended)\n\nIf you want the convenience of having Google Cloud take care of the\nbackend database and server administration chores, we recommend that you use\n[Cloud SQL](/sql/docs/introduction).\nCloud SQL provides the following advantages:\n\n- Automated backups\n- Point-in-time recovery\n- Replication of your data across multiple [zones](/docs/geography-and-regions) for greater availability and resiliency.\n\nIf you require MySQL features that Cloud SQL doesn't support, such as\nuser defined functions or the SUPER privilege, you can explore the options that\nfollow. For more information about the features that Cloud SQL\nsupports, see the\n[Cloud SQL FAQ](/sql/faq#supportmysqlfeatures).\n\n### Explore Google Cloud Marketplace deployment options\n\nCloud Marketplace offers several options for MySQL installations,\nincluding:\n\n- A standalone MySQL installation\n- LAMP stacks\n- LEMP stacks\n- Nginx stacks\n- A Percona MySQL Cluster installation\n\nBrowse available MySQL installation options from Cloud Marketplace in\nthe Google Cloud console:\n\n[Go to Google Cloud Marketplace](https://console.cloud.google.com/marketplace/browse?q=mysql)\n\n### Manually install MySQL\n\nIf the previous options don't fit your requirements, such as if you want to\ndeploy MySQL on a custom image you created, or if you want complete control of\nthe installation process, you can manually install MySQL by creating a\nCompute Engine instance and installing MySQL directly onto it. For more\ndetailed instructions, see\n[Install MySQL on Compute Engine](/compute/docs/instances/mysql/setup-mysql).\n\nWhat's next\n-----------\n\n- For best practices and tips for running MySQL workloads on Compute Engine, see [Configure MySQL on Compute Engine](/compute/docs/instances/mysql/mysql-workloads).\n- For more information about Cloud SQL, see the [Cloud SQL for MySQL documentation](/sql/docs/mysql).\n- Browse the MySQL installation options from Cloud Marketplace in the\n Google Cloud console:\n\n [Go to Cloud Marketplace](https://console.cloud.google.com/marketplace/browse?q=mysql)\n- To manually install MySQL on a Compute Engine instance, see\n [Install MySQL on Compute Engine](/compute/docs/instances/mysql/setup-mysql)."]]