RadarTrek
Lesson 01 / 10·8 minFree

What Is Redis?

In-memory data store: what Redis is and when to reach for it

Written by the RadarTrek editorial team · June 2026

RAM vs disk: the speed that changes everything

Every database you have ever used — PostgreSQL, MySQL, SQLite — stores its data on disk. Disk is cheap and persistent, which is great. But disk reads are slow: even a fast NVMe SSD delivers data in microseconds. RAM delivers data in nanoseconds — roughly 100× faster. Redis lives entirely in RAM. When your application asks Redis for a value, the round-trip is measured in fractions of a millisecond. That speed difference is why Redis exists.

Redis is not a replacement for your database

Redis and PostgreSQL solve different problems. PostgreSQL is your system of record: it stores structured relational data durably on disk. Redis is your speed layer: it stores a smaller, carefully chosen subset of data in memory so you can access it instantly. You will almost always run both. The question is not "which one?" but "what does each one own?"

💡

The whiteboard analogy

Your PostgreSQL database is the filing cabinet — holds everything permanently, but you have to walk across the room to get a file. Redis is the whiteboard right next to your desk — holds only what you are actively working on, but you can read and update it without moving.

The five most common Redis use cases

Redis is a general-purpose tool, but these five patterns appear in almost every production application:

  • CachingStore the result of a slow database query or API call. Next request returns the cached result in under 1 ms.
  • Session storageKeep user session data (auth tokens, shopping carts) in Redis so any server in your cluster can read it.
  • Rate limitingCount how many requests a user has made in the last minute. Increment a counter in Redis and reject if over the limit.
  • Job queuesPush background tasks (send email, resize image) to a Redis list. Worker processes consume and execute them.
  • Pub/SubBroadcast real-time events (new message, order placed) to all connected services without them polling a database.

Redis is not just a cache

The word "cache" is often the first thing you hear about Redis, but it undersells what it does. Redis ships with six distinct data structures — strings, hashes, lists, sets, sorted sets, and streams — each designed for a specific class of problem. As you work through this course you will learn when to reach for each one.

!

Persistence options

Redis can persist data to disk via RDB snapshots and AOF (append-only file) logging. By default it persists, so a Redis restart does not necessarily mean you lose everything. Managed services like Upstash enable persistence by default.

Installing Redis locally

On macOS, the fastest path is Homebrew. On Windows, use WSL2 with the Ubuntu Redis package. Alternatively, sign up for a free Upstash account and get a Redis URL without installing anything — this is what we recommend for Next.js and serverless work.

macOS install (Homebrew)

# Install
brew install redis

# Start as background service
brew services start redis

# Test the connection
redis-cli ping
# → PONG

RadarTrek Intel — monthly score updates

We track 40+ tools so you don't have to. Score changes, new tools, and new guides — once a month, no spam.