// free tool

Redis connection string builder

Build a Redis or Valkey connection URI, a StackExchange.Redis configuration string or a redis-cli command from one form, or paste one to see what each option does and whether the password crosses the network in plain text. It all runs in your browser: nothing you type is sent anywhere.

Open this connection in SQLly

Opens SQLly's connection editor filled in.

Private by design. The builder and decoder are plain JavaScript running in this tab. The page sends no request with what you type, stores nothing (not even in your browser), and keeps working offline once loaded. The Open in SQLly link goes from your browser straight to the app on your computer.

Redis connection string formats

Almost every Redis client takes a URI: redis://[[user]:password@]host[:port][/db], or rediss:// for TLS. The .NET client StackExchange.Redis is the exception: it uses a comma-separated configuration string such as host:6380,password=...,ssl=true.

redis:// is plain text, AUTH password included. Managed services (Azure Cache for Redis, ElastiCache with in-transit encryption, Upstash) want rediss://.

URI with TLS redis-py, node-redis, ioredis, go-redis, Lettuce, Jedis, SQLly

rediss://:[email protected]/0

URI with an ACL user (Redis 6+) same

rediss://app_user:[email protected]:6380/0

StackExchange.Redis .NET

cache.example.com:6380,password=your_password,ssl=true,abortConnect=false

redis-cli command line

redis-cli -h cache.example.com -p 6380 --tls --askpass

Placeholders such as your_password are just that: build your own string with the form above. More about connecting SQLly to Redis: SQLly for Redis.

Redis URI parts

redis and rediss are provisional IANA URI schemes. Percent-encode special characters in the user and password. A password with no user (redis://:pw@host) signs in as the default user.

KeywordSynonymsDefaultWhat it does
scheme - redis redis:// plain TCP, rediss:// TLS. Valkey clients accept the same; some also take valkey://.
user - default ACL user name (Redis 6+).
password - - AUTH password.
host:port - localhost:6379 Server address.
/db ?db= 0 Database index, 0 to 15 by default.

StackExchange.Redis configuration options

Format: host:port[,host2:port2],option=value,.... Option names are case-insensitive. A password containing a comma cannot be written in the string; set ConfigurationOptions.Password in code.

KeywordSynonymsDefaultWhat it does
password - - AUTH password.
user - - ACL user name.
ssl - false Use TLS. With ssl=true and no port the default port is 6380.
sslHost - - Host name the certificate must match.
abortConnect - true (false for Azure Cache for Redis) false keeps retrying in the background instead of throwing from Connect.
connectTimeout - 5000 Milliseconds.
syncTimeout - 5000 Milliseconds for synchronous operations.
asyncTimeout - syncTimeout Milliseconds for async operations.
connectRetry - 3 Connect attempts.
defaultDatabase - - Database index.
name - - Client name (CLIENT SETNAME).
allowAdmin - false Allow FLUSHALL, CONFIG and other admin commands.
keepAlive - -1 (60 s) Seconds between keepalive pings.
serviceName - - Sentinel master name.

redis-cli connection flags

redis-cli also accepts -u redis://....

KeywordSynonymsDefaultWhat it does
-h - 127.0.0.1 Host.
-p - 6379 Port.
--user - - ACL user (with a password).
-a / --pass - - Password on the command line; visible in shell history and the process list. Prefer --askpass or the REDISCLI_AUTH environment variable.
-n - 0 Database index.
--tls - - Use TLS; add --cacert for a private CA.

Common Redis connection errors

NOAUTH Authentication required.

Why: The server has a password (requirepass or ACL users) and the client sent a command without authenticating, usually because the password is missing from the URI.

Fix: Add the password: redis://:password@host:6379, or redis://user:password@host for an ACL user.

WRONGPASS invalid username-password pair or user is disabled.

Why: Redis 6+ rejected the credentials. Often the password was given as a user name: some clients read redis://secret@host as user secret with no password.

Fix: Write redis://:secret@host (note the colon) or give both user and password.

It was not possible to connect to the redis server(s).

Why: StackExchange.Redis could not connect: wrong host or port, TLS required but ssl=true missing (or the other way round), or a firewall. With abortConnect=true (the default) it throws immediately.

Fix: Check ssl and the port (TLS endpoints are often 6380), and set abortConnect=false so the multiplexer keeps retrying.

DENIED Redis is running in protected mode because protected mode is enabled

Why: A Redis with no password and no explicit bind address refuses connections from other machines.

Fix: Set a password (or ACL users) and a bind address on the server rather than turning protected mode off.

Redis connection string FAQ

What is the Redis connection string format?

redis://[[user]:password@]host[:port][/db], or rediss:// for TLS. For example rediss://:[email protected]:6380/0. StackExchange.Redis uses host:port,password=...,ssl=true instead.

What is the default Redis port?

6379. Many managed services serve TLS on 6380, and StackExchange.Redis assumes 6380 when ssl=true and no port is given.

How do I put a username in a Redis URI?

Redis 6 added ACL users: redis://user:password@host:6379. With only a password, write redis://:password@host; the server signs you in as the default user.

Do these strings work for Valkey?

Yes. Valkey is protocol-compatible with Redis, so the same URIs, configuration strings and redis-cli flags (or valkey-cli) work. SQLly also reads valkey:// and valkeys://.

// skip the strings entirely

Connect once. Then just write SQL.

SQLly is a native SQL workbench for macOS, Windows and Linux. Paste a connection string into its connection editor, keep passwords in your system keychain, and get schema-aware IntelliSense on Redis and more.