Parse a libpq connection URI (postgres://user:pass@host:port/db?sslmode=…) or a keyword=value DSN (host=localhost user=postgres …) into structured fields, edit any part, and round-trip back out. Convert the result to JDBC, .NET / Npgsql, Node pg, psql CLI, environment variables, and Docker Compose — all in your browser. Passwords are never logged or sent anywhere.
| Key | Value |
|---|
Connection URIs follow RFC 3986 and libpq's documented format postgresql://[userspec@][hostspec][/dbname][?paramspec]. Both postgres:// and postgresql:// schemes are accepted. Multiple hosts are comma-separated and tried in order; the optional target_session_attrs parameter (default any) can require read-write, read-only, primary, or standby — how libpq picks the primary in a failover URL.
For Unix-domain sockets, use a percent-encoded path as the host (/var/run/postgresql → %2Fvar%2Frun%2Fpostgresql) or pass host=/var/run/postgresql in keyword form.
sslmode values progress from no encryption (disable) to encryption + full certificate verification (verify-full) — only the last two protect you against MITM attacks; require alone trusts any cert the server presents.