MySQL setup
How to connect a MySQL database. The flow mirrors PostgreSQL, with a couple of differences.
What you need
Name
A label so you can recognise the connection.
A label so you can recognise the connection.
Driver
Choose MySQL.
Choose MySQL.
Host & Port
Your database host and port (MySQL defaults to 3306).
Your database host and port (MySQL defaults to 3306).
Database
The database name to connect to.
The database name to connect to.
User & Password
Credentials STYD will use — prefer a read-only user.
Credentials STYD will use — prefer a read-only user.
The schema selector is specific to PostgreSQL, so it does not apply to a MySQL connection.
Steps
Open Settings → Connections, choose Add a connection, then A database.
Select MySQL as the database type and enter the server address, port, database, user, and password.
Choose Test connection.
Choose Save connection. STYD then offers to analyse the database with the AI Guide: the first analysis may be included, otherwise it shows the price and asks an owner or admin to confirm.
Network and access
STYD connects from the internet and only runs read queries. Your database must be reachable at a public address, and the port must be open through any firewall or security group. If your server only accepts approved addresses, allow STYD’s two addresses: 109.123.235.222 (IPv4) and 2407:3640:2324:5796::1 (IPv6). On the database side, also check bind-address and that the user’s host part allows connections from outside your network.
A database on
localhost or on a private network (for example 10.x, 192.168.x) is not reachable from STYD Cloud, and there is no SSH tunnel option. If that is your situation, a custom, private installation can reach it: see Custom AI.If the address goes through Cloudflare’s proxy (the orange cloud), it cannot carry database connections. Use a DNS-only name, or the server’s own address.
STYD lists MySQL as a supported driver. If you run a MySQL-compatible database, confirm compatibility with a test connection before relying on it.
Safety
Use a read-only database user, do not expose production credentials publicly, and test the connection before using it in chat.