> ## Documentation Index
> Fetch the complete documentation index at: https://docs.vortexiq.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Total Keys (db0), Redis

> Total Keys (db0) for Redis instances. Tracked live in Vortex IQ Nerve Centre. How to read it, why it matters, and how to act on it.

**Card class:** [Non-Hero](/nerve-centre/overview#card-classes-explained)  •  **Category:** [Cache](/nerve-centre/connectors#connectors-by-type)

## At a glance

> **Total Keys (db0)** is the number of keys currently held in logical database 0, read straight from `INFO keyspace` (the `db0:keys=` field). It is the simplest possible measure of how much your Redis instance is holding. Watch the trend, not the absolute number: a flat or gently rising key count is normal, while a sudden cliff usually means a flush, an eviction storm, or a mass-expiry event.

|                    |                                                                                                                                                                                                                                  |
| ------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **What it tracks** | The `keys=` value parsed from the `db0:` line returned by `INFO keyspace`. Most ecommerce Redis deployments keep everything in db0, so this is the working key population for caches, sessions, rate-limit counters, and queues. |
| **Data source**    | `INFO keyspace`, `db0:keys=`. The same line also reports `expires=` (keys with a TTL) and `avg_ttl`.                                                                                                                             |
| **Time window**    | `RT` (real-time, read on each refresh).                                                                                                                                                                                          |
| **Alert trigger**  | None by default. This is a context metric; pair it with eviction and memory cards for alerting.                                                                                                                                  |
| **Roles**          | engineering, operations                                                                                                                                                                                                          |

## What it tracks

Redis groups keys into numbered logical databases (0 to 15 by default). The overwhelming majority of production workloads, and every managed offering that disables `SELECT` such as Amazon ElastiCache cluster mode and Redis Cluster, keep all data in db0. This card reports the live `keys=` count for that database, parsed from `INFO keyspace`. A steadily growing count with no matching TTL coverage is the classic signature of an unbounded cache that will eventually hit `maxmemory` and start evicting. A flat count that suddenly drops to near zero almost always means a `FLUSHDB`, a failover to a cold replica, or a mass expiry. Read it next to [Evicted Keys / minute](/nerve-centre/kpi-cards/redis/evicted-keys-minute) and [Memory Used vs Maxmemory %](/nerve-centre/kpi-cards/redis/memory-used-vs-maxmemory) to tell growth from pressure.

## Reconciling against the source

Run `redis-cli INFO keyspace` and read the `db0:keys=` field, or run `redis-cli DBSIZE` for the same count without the surrounding stats. On Amazon ElastiCache the equivalent is the `CurrItems` CloudWatch metric. Small differences between our reading and a manual check are expected because keys expire continuously between samples.

***

### Tracked live in Vortex IQ Nerve Centre

*Total Keys (db0)* is one of hundreds of KPI pulses Vortex IQ tracks across Redis and 70+ other ecommerce connectors. Nerve Centre runs the detection layer; Vortex Mind investigates the cause when something moves; Ask Viq lets you interrogate any number in plain English.

[Start for free](https://app.vortexiq.ai/login) or [book a demo](https://www.vortexiq.ai/contact-us) to see this metric running on your own data.
