About this tool
Build a database connection URI for Postgres, MySQL, MongoDB, Redis and more — with the right scheme and default port.
The Database Connection String Builder assembles a URI in the form scheme://user:password@host:port/database for PostgreSQL, MySQL, MariaDB, MongoDB, Redis and SQL Server, filling in the correct scheme and the engine's default port — 5432, 3306, 27017, 6379 and 1433 — whenever you leave the port blank. Developers wiring up a DATABASE_URL or a container environment file get the exact string plus a breakdown of the scheme, host, port and database name it used. Credentials are typed in plain text, so use throwaway values rather than production secrets.
Open Database Connection String Builder on AltFTool — it loads instantly in your browser.
Pick your engine in the 'Database' dropdown — the options read PostgreSQL, MySQL, MariaDB, MongoDB, Redis and SQL Server — or click 'Postgres local' or 'MongoDB' in the Examples row to fill the whole form at once. The scheme follows the engine, so MariaDB emits mysql:// and SQL Server emits sqlserver://.
Set 'Host' (pre-filled with localhost) and leave the field labelled 'Port (blank = default)' empty to fall back to that engine's standard port — 5432, 3306, 27017, 6379 or 1433 — or type a number to override it. Host is the only required field; clear it and the panel reads "Enter Host to see the result."
Add 'Username', 'Password' and 'Database name'. The URI rebuilds live under Result as you type — there is no button to press — with Scheme, Host, Port and Database listed beneath it. Copy puts a plain-text summary on the clipboard (the tool title, your field values, then a 'Result:' line) and Download saves it as connection-string-builder.txt. Never paste production secrets: the password is shown in clear text.
Leave the port blank and it inserts the documented default for that database rather than producing a portless string that silently falls back somewhere else.
MariaDB emits the mysql:// scheme and SQL Server emits sqlserver://, which are the two cases people most often get wrong by typing the product name.
Omitting the username drops the whole auth segment and omitting the database name drops the trailing path, so you get a valid URI instead of stray colons and slashes.
PostgreSQL 5432, MySQL and MariaDB 3306, MongoDB 27017, Redis 6379, and SQL Server 1433. Those are the values inserted automatically when the port field is left empty.
scheme://username:password@host:port/database — for example postgresql://admin:secret@localhost:5432/app. The username and password segment and the trailing database path are both optional, and the scheme identifies the driver rather than the product name.
Percent-encode them yourself before pasting the password in. Characters such as @, :, /, ? and # are structural in a URI, so a password like p@ss must appear as p%40ss — this builder inserts the password as typed and does not encode it for you.
No. The password is displayed in plain text in the result and in your browser's form state, so use a placeholder and substitute the real secret in your own environment file or secret manager. Anything you have already pasted into any web tool should be treated as needing rotation.