Tool guide
About this tool.
- A connection string packs everything a client needs to reach a database into one URL: scheme, optional user and password, one or more hosts with ports, a database name and query options. PostgreSQL, MySQL, MongoDB and Redis all use this shape, with small differences in what the path and options mean.
- The parser reads the scheme, splits the authority at its last @, percent-decodes the credentials and lists every host with its port and whether the default port applies. It reports the options in order and whether TLS is on, optional or off, then adds findings such as credentials in the URL or a connection that can be unencrypted.
- The builder does the reverse. Pick a dialect, fill in the fields and it prints the URI with percent-encoded credentials, the JDBC form for PostgreSQL and MySQL, and a ready .env line.
- Check which host, port and database a pasted DATABASE_URL really points to, and whether TLS is requested.
- Find out why a password with @, / or : breaks a URL: it must be percent-encoded, and the builder does that for you.
- Produce the URI, JDBC and .env variants of one connection without hand-editing each. Use URL Parse for generic URLs, Secret Redactor before sharing a real string and Dotenv Formatter to tidy the result.
Choose Parse to analyze a pasted connection string or Build to write one from fields.
In Parse mode paste a postgres, postgresql, jdbc:postgresql, mysql, jdbc:mysql, mongodb, mongodb+srv, redis or rediss URL.
In Build mode pick the dialect and enter host, optional port, credentials, database and options, one key=value per line.
Copy or download the result. Passwords are not redacted.
- postgres://app:s3cr%[email protected]:5433/appdb?sslmode=require → PostgreSQL, port 5433, TLS on, password s3cr@t.
- jdbc:postgresql://localhost/app → default port 5432, TLS optional, a medium finding: libpq defaults to prefer, which can fall back to unencrypted.
- mongodb://a.example:27017,b.example:27018/app?replicaSet=rs0 → two hosts and the replicaSet option.
- rediss://:[email protected]:6380/2 → Redis database 2 over TLS with a password and no user.
- mysql://u@h/db?ssl-mode=REQUIRED → TLS on, no password.
- Build PostgreSQL with user app, password s3cr@t and TLS → postgresql://app:s3cr%[email protected]:5432/appdb?sslmode=require plus JDBC and DATABASE_URL lines.
- Input is at most 8,192 characters. Passwords are shown exactly as pasted. Build mode rejects a host containing / ? # @ , or spaces.
- Parsing splits the authority at the last @ and the user from the password at the first colon; both are percent-decoded. A raw @ or / before the last @ is rejected.
- Default ports are 5432 for PostgreSQL, 3306 for MySQL, 27017 for MongoDB and 6379 for Redis; the report marks each host that uses one.
- JDBC strings for PostgreSQL and MySQL may carry user and password as query options; the report reads them as credentials.
- The builder always writes the port, appends the TLS option first and your options after it, and uses rediss:// for Redis with TLS. MySQL requires TLS with ssl-mode=REQUIRED in the URI and sslMode=REQUIRED in the JDBC form.
- The builder percent-encodes the database name and each option name and value, so enter them unencoded.
- The .env line is NAME="uri" with " and \ escaped; the name is DATABASE_URL, MONGODB_URI or REDIS_URL.
- No SQL Server, SQLite, ODBC or LDAP strings, and no connection is opened or tested.