# REPLICATION.INFO

> Return this node's replication role, state, offset and number of replicas.

URL: https://docs.hotkv.com/commands/replication-info/

```
REPLICATION.INFO
```

- Group: Replication
- Complexity: O(1)
- HotKV Cloud: Scale plan
- On-Premise: requires the replication license feature

`REPLICATION.INFO` gives a short summary of HotKV's replication on this
node: whether it is a primary or a replica, what its link is doing, how far
its replication stream has got, and how many replicas are attached. For the
full picture, see the `replication` section of [INFO](https://docs.hotkv.com/commands/info/index.md).

## Return value

A flat array of field and value pairs, in RESP2 and RESP3:

| Field | Type | Meaning |
| --- | --- | --- |
| `role` | Bulk string | `primary`, `replica` or `candidate` |
| `state` | Bulk string | `disconnected`, `connecting`, `syncing`, `streaming`, `paused` (after [REPLICATION.PAUSE](https://docs.hotkv.com/commands/replication-pause/index.md)) or `electing` |
| `repl_offset` | Integer | The replication offset: how far this node's replication stream has got |
| `connected_replicas` | Integer | Replicas attached to this primary (0 on a replica) |

Without a license that includes `replication`, the reply is
`NOLICENSE replication requires a HotKV license. Contact sales@hotkv.com`.

## Examples

```
127.0.0.1:6379> REPLICATION.INFO
1) "role"
2) "primary"
3) "state"
4) "streaming"
5) "repl_offset"
6) (integer) 1849302
7) "connected_replicas"
8) (integer) 2
```

## Compatibility

HotKV-only command. Redis and Valkey report replication in `INFO
replication` and `ROLE`, which HotKV also supports.

## See also

[REPLICATION.PAUSE](https://docs.hotkv.com/commands/replication-pause/index.md),
[REPLICATION.RESUME](https://docs.hotkv.com/commands/replication-resume/index.md),
[REPLICATION.FAILOVER](https://docs.hotkv.com/commands/replication-failover/index.md),
[INFO](https://docs.hotkv.com/commands/info/index.md), [ROLE](https://docs.hotkv.com/commands/role/index.md)