How to create a redis cloud connection url with an auth password

Viewed 45820

I'm switching over from a heroku addon to a direct redis cloud account and am a bit puzzled on how to generate the redis url with the auth info.

The old heroku add-on url was in the format of redis://rediscloud:mypassword@redis...

However in the dashboard and documentation I don't see any mention of a username to go along with the password. Do I still set rediscloud as the username in my new account and connection string. Does it even matter what I set as the username there?

3 Answers
  • Version 6+ now supports users: https://redis.io/topics/acl
  • If you aren't using an Access Control List (ACL) for your instance (meaning you auth as the default user) or are using an older version of Redis, you should omit the username from your Redis URL (e.g., redis://rediscloud:mypassword@...redis://:mypassword@...)
  • If you include a username like rediscloud in the URL and your instance doesn't have that user configured in your ACL, you will likely run into auth issues for WRONGPASSWORD errors as more Redis client libraries implement ACL support.
Related