Use a single connection string, including DB number.
Section: Connecting and basic redis-cli use
Connect using a Redis URL
bash
bash
redis-cli -u redis://:password@redis.example.com:6379/0Learn the surrounding workflow
Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.
Related commands
Same sheet · prioritizing Connecting and basic redis-cli use