What is MySQL?

MySQL is the world's most widely used open source relational database. CloudSonic offers fully managed MySQL with automated backups, replication, and performance tuning included.

CloudSonic
CloudSonic
Last Updated September 10, 2026

TL;DR MySQL

MySQL is the world's most widely used open source relational database management system. It organises data into tables made up of rows and columns and uses SQL, Structured Query Language, to create, read, update, and delete records. MySQL powers an enormous proportion of the web including WordPress, WooCommerce, and thousands of other popular applications, which is why understanding it is fundamental to web hosting. It is known for being fast, reliable, and well-supported with a huge ecosystem of tools, documentation, and community knowledge. CloudSonic offers fully managed MySQL with automated backups, replication, and performance tuning taken care of for you. If you need a MySQL-compatible database with additional features, MariaDB is also available as a fully managed option on CloudSonic.

How MySQL Works

MySQL operates as a client-server system. The MySQL server process runs continuously in the background, listening for connections from client applications. When WordPress needs to read or write data, it opens a connection to MySQL using credentials stored in the wp-config.php file, sends a SQL query, receives the result, and closes the connection or returns it to a connection pool. MySQL processes the query by first parsing it to check for syntax errors, then passing it to the query optimiser which generates an execution plan, then executing that plan against the data stored on disk and in memory. The InnoDB buffer pool, which CloudSonic sizes to approximately 30 percent of available RAM, caches frequently accessed data pages in memory so that repeated queries can be answered from RAM rather than requiring a disk read, significantly improving response times for busy sites.


# Create a new MySQL database and user with the CloudSonic helper
db-create mysite_db mysite_user

# Output:
# Database:  mysite_db
# User:      mysite_user
# Password:  xK9mP2nQvR7wL4tY
# Host:      127.0.0.1
# Port:      3306
# DSN:       mysql://mysite_user:xK9mP2nQvR7wL4tY@127.0.0.1:3306/mysite_db

# Create a new PostgreSQL database and user with the CloudSonic helper
pgdb-create mysite_db mysite_user

# Output:
# Database:  mysite_db
# User:      mysite_user
# Password:  xK9mP2nQvR7wL4tY
# Host:      127.0.0.1
# Port:      5432
# DSN:       postgresql://mysite_user:xK9mP2nQvR7wL4tY@127.0.0.1:5432/mysite_db

Frequently Asked Questions on MySQL

Why does WordPress use MySQL rather than PostgreSQL?

WordPress was built on MySQL from the beginning in 2003 and its database schema and query patterns are tightly coupled to MySQL-specific features and syntax. Migrating WordPress core to support PostgreSQL natively would require significant changes to the codebase. There are plugins that add PostgreSQL compatibility but they are not officially supported and have limitations. For native PostgreSQL support, consider a custom application or API rather than WordPress.

How many database connections can MySQL handle simultaneously?

The number of simultaneous connections MySQL can handle is determined by the max_connections configuration setting and the available server memory, since each connection consumes RAM. On a CloudSonic server the value is sized appropriately for the available RAM. For high-traffic sites where connection exhaustion is a concern, a connection pooler like ProxySQL can multiply the effective connection capacity significantly.

Does MySQL slow down as the database grows larger?

A growing database can slow down queries if tables are not properly indexed, if the InnoDB buffer pool is too small to cache the working set of data, or if table statistics become stale and the query optimiser makes poor execution plan choices. Regular database maintenance including index optimisation and statistics updates prevents this. CloudSonic manages these maintenance tasks as part of the managed database service.