Connect your first database

Add a MySQL, MariaDB, or PostgreSQL connection to Cocobox in under a minute.

Last updated

Cocobox supports MySQL, MariaDB, and PostgreSQL today. SQLite, MSSQL, and ClickHouse are on the roadmap.

1. Open the Connections panel

In the app sidebar, click Connections → New connection.

2. Pick a dialect

Choose MySQL, MariaDB, or PostgreSQL. The form changes slightly per dialect (default ports, SSL options).

3. Fill in the basics

FieldNotes
NameA human-readable label that shows up in the sidebar.
HostPublic hostname or IP. If your DB is private, enable SSH tunnel.
PortDefaults: 3306 (MySQL/MariaDB), 5432 (PostgreSQL).
DatabaseThe default schema/database to connect to. You can switch later.
UsernameA read-only user is recommended for first connection.
PasswordStored encrypted at rest with a per-user key. We never log it.
SSL / TLSOn by default for cloud DBs. See SSL / TLS.

4. Test the connection

Click Test connection. Cocobox dials your host, opens a session with your credentials, runs SELECT 1 (or SELECT version() on Postgres), then immediately disconnects.

If the test passes, click Save. The new connection appears in the sidebar.

5. Browse the schema

Click the new connection in the sidebar. Cocobox loads the schema tree (databases → tables → columns + indexes) on demand. Right-click a table for quick actions: Preview, Describe, ER diagram, Generate INSERT.

Common errors

  • ECONNREFUSED — the host or port is wrong, or the DB only listens on localhost. Use SSH tunneling.
  • Access denied for user — wrong credentials or the user lacks the CONNECT / SELECT privilege on the target database.
  • SSL connection error — your DB requires a specific SSL mode. Toggle between require, verify-ca, and verify-full under SSL options.

Next steps