Join the AI Workshop to learn more about AI and how it can be applied to web development. Next cohort February 1st, 2026
The AI-first Web Development BOOTCAMP cohort starts February 24th, 2026. 10 weeks of intensive training and hands-on projects.
Redis implements a publish/subscribe messaging mechanism.
Its concept is simple: a publisher sends a message on a channel. Multiple subscribers receive it.
Subscribe to a channel using
SUBSCRIBE <channel>
Publish to a channel using
PUBLISH <channel> <message>
Example:
SUBSCRIBE dogs

In another redis-cli window, type:
PUBLISH dogs "Roger"

Messages will be sent to the subscribers, and they’ll by default display the kind of event, the channel, and the message:

Subscribers can listen on multiple channels:
SUBSCRIBE dogs cats
and will receive messages coming from all of them.