# redis/ioredis

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/redis-ioredis).**

15,295 stars · 1,228 forks · TypeScript · MIT

## Links

- GitHub: https://github.com/redis/ioredis
- awesome-repositories: https://awesome-repositories.com/repository/redis-ioredis.md

## Topics

`nodejs` `redis` `redis-client` `redis-cluster` `redis-module` `redis-sentinel` `typescript`

## Description

ioredis is a performance-focused Redis client for Node.js applications. It provides a comprehensive interface for interacting with Redis servers, including specialized clients for sharded clusters and Sentinel-based high availability environments.

The project distinguishes itself through advanced networking and execution capabilities, such as automatic event-loop pipelining to reduce overhead and a system for routing read-write traffic between primary and replica nodes. It also features a dedicated Lua scripting interface that allows server-side scripts to be registered as custom client commands.

The library covers a broad range of data management and communication patterns, including stream processing with consumer groups, real-time pub/sub messaging, and geospatial querying. It provides integrated support for atomic transactions, binary data handling, and vector similarity search, alongside security features like TLS encryption and ACL permission management.

Operational stability is supported through a retry-strategy state machine, offline command queuing, and incremental collection scanning to prevent server blocking.

## Tags

### Data & Databases

- [Redis Client Interfaces](https://awesome-repositories.com/f/data-databases/redis-client-interfaces.md) — Provides a comprehensive standard interface for manipulating Redis data structures like hashes, vectors, and streams. ([source](https://github.com/redis/ioredis/blob/main/CHANGELOG.md))
- [Redis Clients](https://awesome-repositories.com/f/data-databases/redis-clients.md) — Provides a performance-focused Node.js client for interacting with Redis data stores and complex data types.
- [Cluster Request Routing](https://awesome-repositories.com/f/data-databases/connection-managers/cluster-request-routing.md) — Maps keys to hash slots to route requests to the correct node in a sharded cluster.
- [Key Expiration Policies](https://awesome-repositories.com/f/data-databases/data-governance-modeling/data-management-governance/data-lifecycle-retention/data-lifecycle-management/key-expiration-policies.md) — Supports setting time-to-live values on keys to automatically manage data expiration and memory usage. ([source](https://redis.github.io/ioredis/classes/Cluster.html))
- [Redis Stream Processors](https://awesome-repositories.com/f/data-databases/data-processing-pipelines/stream-processing-systems/data-streaming/structured-event-streams/streaming-processors/redis-stream-processors.md) — Implements client-side utilities for managing Redis streams and consumer groups in event-driven architectures. ([source](https://github.com/redis/ioredis#readme))
- [Hash Field Management](https://awesome-repositories.com/f/data-databases/hash-field-management.md) — Provides comprehensive support for manipulating field-value pairs in Redis hashes for complex object management. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Key-Value Stores](https://awesome-repositories.com/f/data-databases/key-value-stores.md) — Stores and manipulates simple text or binary values with support for atomic increments. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Ordered Collection Management](https://awesome-repositories.com/f/data-databases/ordered-collection-management.md) — Handles sequential lists of strings using push, pop, and positional retrieval operations. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Cluster Connectivity](https://awesome-repositories.com/f/data-databases/redis-clients/cluster-connectivity.md) — Provides connectivity mechanisms for interacting with Redis clustered data stores using slot-based routing. ([source](https://redis.github.io/ioredis/classes/Cluster.html))
- [Sentinel Management](https://awesome-repositories.com/f/data-databases/sentinel-management.md) — Integrates with Redis Sentinel to locate the current master node and handle automatic failover events. ([source](https://github.com/redis/ioredis#readme))
- [Connection Modes](https://awesome-repositories.com/f/data-databases/sentinel-management/connection-modes.md) — Supports flexible connection options for standalone instances or Sentinel high-availability groups. ([source](https://github.com/redis/ioredis#readme))
- [Sharding Orchestration](https://awesome-repositories.com/f/data-databases/sharding-orchestration.md) — Manages data distribution and partitioning across multiple shards to ensure connection stability. ([source](https://github.com/redis/ioredis#readme))
- [Sorted Sets](https://awesome-repositories.com/f/data-databases/sorted-sets.md) — Manages unique strings ordered by numerical scores to enable efficient ranking and range queries. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Unordered Unique Collection Management](https://awesome-repositories.com/f/data-databases/unordered-unique-collection-management.md) — Manages collections of unique strings with support for set intersections, unions, and differences. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Cardinality Estimation](https://awesome-repositories.com/f/data-databases/cardinality-estimation.md) — Calculates approximate unique element counts in large sets using the HyperLogLog algorithm. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Command Pipelining](https://awesome-repositories.com/f/data-databases/command-pipelining.md) — Queues multiple commands in memory and sends them in a single network round-trip to increase throughput. ([source](https://github.com/redis/ioredis/blob/main/README.md))
- [Namespace Prefixing](https://awesome-repositories.com/f/data-databases/data-engineering-infrastructure/caching-performance/caching-strategies/cache-key-generators/namespace-prefixing.md) — Automatically prepends specified strings to keys to organize data into transparent namespaces. ([source](https://github.com/redis/ioredis/blob/main/README.md))
- [Atomic Transactions](https://awesome-repositories.com/f/data-databases/database-management-systems/database-systems-management/connection-transaction-management/atomic-transactions.md) — Groups multiple commands into atomic blocks to ensure sequential execution without interruption. ([source](https://github.com/redis/ioredis/blob/main/README.md))
- [Database Key Scanning](https://awesome-repositories.com/f/data-databases/database-management-systems/database-systems-management/database-operations/database-key-scanning.md) — Implements non-blocking cursor-based iteration for scanning database keys. ([source](https://github.com/redis/ioredis/blob/main/README.md))
- [Geospatial Query Engines](https://awesome-repositories.com/f/data-databases/geospatial-query-engines.md) — Executes distance calculations and proximity searches using coordinate-based geospatial storage. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [High Availability Architectures](https://awesome-repositories.com/f/data-databases/high-availability-architectures.md) — Implements high availability architectures using Redis Sentinel for automatic failover and monitoring.
- [Incremental Collection Scanning](https://awesome-repositories.com/f/data-databases/incremental-collection-scanning.md) — Implements cursor-based iteration to retrieve keys or members without blocking the Redis server. ([source](https://redis.github.io/ioredis/classes/Cluster.html))
- [Raw Command Execution](https://awesome-repositories.com/f/data-databases/raw-command-execution.md) — Allows sending raw command names and arguments directly to the Redis server. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Traffic Routing](https://awesome-repositories.com/f/data-databases/read-replicas/traffic-routing.md) — Routes write operations to primary nodes and distributes read operations across replica nodes.
- [Redis Performance Tuning](https://awesome-repositories.com/f/data-databases/redis-performance-tuning.md) — Provides tools for reducing network latency and increasing throughput via pipelining and read-write splitting.
- [Server-Side Scripting](https://awesome-repositories.com/f/data-databases/server-side-scripting.md) — Executes custom Lua scripts on the server side for atomic, high-performance operations. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Cursor-based Iterators](https://awesome-repositories.com/f/data-databases/storage-engines/cursor-based-iterators.md) — Uses incremental cursors to retrieve large datasets in chunks to avoid blocking the Redis server.

### Software Engineering & Architecture

- [Event-Loop Pipelining](https://awesome-repositories.com/f/software-engineering-architecture/event-loop-pipelining.md) — Batches multiple commands issued in one event loop tick into a single network request.
- [Automated Retry Strategies](https://awesome-repositories.com/f/software-engineering-architecture/performance-reliability/reliability-patterns/automated-retry-strategies.md) — Provides configurable retry strategies to automatically restore network connections after loss. ([source](https://github.com/redis/ioredis#readme))
- [Retry Strategies](https://awesome-repositories.com/f/software-engineering-architecture/retry-strategies.md) — Implements configurable backoff policies and retry logic to restore network stability.

### Development Tools & Productivity

- [Response Formatters](https://awesome-repositories.com/f/development-tools-productivity/dynamic-command-resolution/command-argument-resolvers/response-formatters.md) — Converts raw server replies into application-specific data types before returning them to the user.
- [Script-Based Command Wrappers](https://awesome-repositories.com/f/development-tools-productivity/shell-configuration-management/reusable-command-blocks/command-abstractions/script-based-command-wrappers.md) — Allows wrapping server-side scripts into reusable custom commands to simplify execution logic. ([source](https://github.com/redis/ioredis#readme))

### DevOps & Infrastructure

- [Automated Master Failovers](https://awesome-repositories.com/f/devops-infrastructure/remote-cluster-access/cluster-failover-managers/automated-master-failovers.md) — Coordinates automated master failover and replica transitions to maintain cluster uptime. ([source](https://redis.github.io/ioredis/classes/Cluster.html))

### Networking & Communication

- [Message Stream Consumer Groups](https://awesome-repositories.com/f/networking-communication/message-stream-handlers/message-stream-consumer-groups.md) — Coordinates consumer groups for parallel and distributed processing of message streams. ([source](https://redis.github.io/ioredis/classes/Redis.html))
- [Offline Buffering](https://awesome-repositories.com/f/networking-communication/network-reliability-diagnostics/connection-session-management/connection-management/offline-buffering.md) — Queues commands issued during network disconnections for automatic execution upon reconnection.
- [Pub-Sub Messaging](https://awesome-repositories.com/f/networking-communication/pub-sub-messaging.md) — Provides asynchronous communication via publish and subscribe channels for real-time message delivery.
- [Topic Sharding](https://awesome-repositories.com/f/networking-communication/pub-sub-messaging/topic-sharding.md) — Distributes pub-sub channel messages across a cluster by mapping them to specific hash slots. ([source](https://github.com/redis/ioredis#readme))

### System Administration & Monitoring

- [Offline Request Queues](https://awesome-repositories.com/f/system-administration-monitoring/background-job-queues/offline-request-queues.md) — Queues commands issued during a disconnection for automatic execution upon reconnection. ([source](https://github.com/redis/ioredis#readme))

### Web Development

- [Response Serialization](https://awesome-repositories.com/f/web-development/response-serialization.md) — Transforms raw network data from the server into preferred application-specific formats. ([source](https://github.com/redis/ioredis#readme))
