Skip to content
pubscout

ioredis

3.2.1, released 4 days ago by dartondox.dev

Redis client for Dart with connection pooling, pub/sub, transactions, and pipelining.

$ flutter pub add ioredis
Source repository

What it does

Provides a fully-featured Redis client supporting strings, hashes, lists, sets, sorted sets, scripting, and pub/sub. Includes automatic pipelining, connection pooling, reconnection logic, and TLS support via URL configuration.

AI-written summary of version 3.0.2, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need to connect a Dart or Flutter application directly to a Redis server
  • You require pub/sub messaging capabilities with binary or text payloads
  • You want automatic command pipelining and connection pooling

Skip it when

  • You need a local embedded key-value database specifically for local device storage without a running Redis server
  • Your application requires an offline-first NoSQL database like Hive or Isar

Strengths

  • Supports pub/sub with both text and binary messages
  • Built-in connection pooling and auto-pipelining
  • Robust reconnection handling with retry strategies and handshake timeouts
  • Supports Redis URL configuration including TLS (rediss://)

Weaknesses

  • Requires a running Redis server network connection
  • Not an embedded local storage solution

Setup

Kind
Pure Dart
Effort
Low
Code generation
No
Direct dependencies
0

Requires a running Redis server instance (or multiple for test suites).

Redis redis = new Redis(RedisOptions(host: '127.0.0.1', port: 6379));
await redis.set('key', 'value');
String? value = await redis.get('key');

Alternatives

Packages that do the same job and could replace ioredis.

  • mongo_dart

    MongoDB driver implemented in pure Dart for server-side applications.

  • neat_cache

    A cache abstraction for wrapping in-memory or redis caches with timeouts.

  • eloquent

    Laravel-style query builder, schema builder, and migrations for PostgreSQL and MySQL.