Connections
Connection by Engine
Engine-specific notes — required fields, default ports and common pitfalls for each supported database.
Most engines use the same five core fields — host, port, database, user, password — but each has its own defaults, quirks and security considerations. Use this page as a reference once you already know the basics from Creating a Connection.
PostgreSQL
Default port: 5432. The most flexible engine — DB AI Magic supports every PostgreSQL feature including schemas, JSON columns, arrays and full-text search.
- Schema — optional; if blank we use
public. - SSL — turn on for cloud-hosted DBs. For self-signed certs, paste your CA into the SSL field.
Read replicas
MySQL / MariaDB
Default port: 3306. MariaDB is fully MySQL-compatible — pick either when adding the connection.
- Authentication plugin — modern MySQL uses
caching_sha2_passwordby default. Both plugins are supported. - Time zone — DB AI Magic reads
NOW()in the server's time zone. Set it explicitly on the server if you want predictable dashboard widgets.
SQL Server / Azure SQL
Default port: 1433. Azure SQL is treated as SQL Server — same form, same fields.
- Encryption — Azure SQL requires encrypted connections. We default to
encrypt=trueso you don't have to think about it. - Instance name — optional; leave blank for the default instance.
MongoDB
Default port: 27017. You can also paste a fullmongodb:// or mongodb+srv:// URI in place of host + port.
- Atlas — paste the SRV URI from the Atlas dashboard and DB AI Magic will resolve the cluster automatically.
- Auth source — usually
adminunless you're using a per-database auth user. - Replica sets — supported; DB AI Magic picks a healthy node automatically.
SQLite
SQLite is the easiest engine to connect: there's no host or port, just a file. Upload the .sqlite /.dbfile in the form and you're done.
Multiple users
CockroachDB
Default port: 26257. CockroachDB is wire-compatible with PostgreSQL — pick PostgreSQL as the engine, point at your Cockroach cluster, and turn SSL on.
Amazon Redshift
Default port: 5439. Use the PostgreSQL engine. Required:
- Cluster endpoint as the host (looks like
cluster.xyz.region.redshift.amazonaws.com). - SSL turned on (Redshift refuses unencrypted connections).
Greenplum
Greenplum is a massively-parallel Postgres derivative. Use the PostgreSQL engine; default port is 5432.
Coming soon engines