jedis is a free, open source databases project written in Java and released under MIT. It has 12,367 GitHub stars, 3,922 forks and 125 open issues, and was last pushed 4 hours ago. On this registry it ranks #67 of 143 tracked projects in Databases, with 5 head-to-head comparisons available.

What is jedis?

Jedis is MIT-licensed Java client for Redis, maintained by Redis, that gives JVM applications direct programmatic access to Redis commands and Redis Cluster, aimed at Java developers and teams running Redis in production.

What it is

Jedis is a Java client library for Redis, distributed on Maven Central as redis.clients:jedis and developed in the redis/jedis repository under the MIT licence. It is a low-level client rather than an object-mapping framework: the README directs anyone wanting a high-level library for object mapping to redis-om-spring instead. The client speaks the Redis command surface directly, exposing data-type operations such as sadd, and it supports the Redis Cluster Specification through a dedicated client class. The project lives in the Java ecosystem, alongside the Redis server itself, and it has been the long-standing default Redis binding for JVM shops.

The concrete problem it solves is the gap between a running Redis server and Java code. Redis speaks its own wire protocol over TCP on port 6379; a Java application cannot call it without a protocol implementation, connection and pooling management, command marshalling, and, for sharded deployments, cluster topology discovery and redirect handling. Jedis replaces hand-rolled socket clients and one-off protocol layers with a maintained library that tracks new Redis releases. Per its compatibility table, the most recent library version supports Redis 7.2 through 8.10, and Jedis 5.0 and later cover Redis 6.0 to current.

Key capabilities

  • Connects to a single Redis node via RedisClient.builder().hostAndPort("localhost", 6379).build(), after which commands such as jedis.sadd("planets", "Venus") are sent directly.
  • Connects to a Redis Cluster using RedisClusterClient, built from a Set of cluster nodes and supporting the Redis Cluster Specification.
  • Covers all Redis data types, including JSON and VectorSets documented in the Redis data-types reference.
  • Version compatibility is tracked explicitly: Jedis 3.9+ targets Redis 5.0 to 6.2, Jedis 4.0+ targets Redis 5.0 to 7.2, and Jedis 5.2+ through 8.0 target Redis 7.2 to current.
  • Runs on JDK 8, 11, 17, 21 and, from Jedis 8.0, JDK 25.
  • Ships Javadocs on javadoc.io and code coverage reporting through codecov for the master branch.
  • Publishes a cutting-edge channel at https://redis.github.io/jedis/jedis-maven/ for unreleased builds.

Who uses it and how

  • Java backend teams that already run Redis for caching, session storage or queues and need a client inside a Spring Boot or plain JVM service.
  • Teams operating sharded Redis where commands must route across multiple nodes; RedisClusterClient takes the node set and handles topology.
  • Applications pinned to older runtimes: the compatibility table explicitly covers JDK 8 and 11, so legacy services are supported targets, not an afterthought.
  • Contributors and integrators working from source, who use the project's Discord channel for the Redis community and Redis University material for onboarding.
  • Developers who want object mapping rather than raw commands are pointed at redis-om-spring, which sits above this client rather than inside it.

Getting started

Add the Maven dependency redis.clients:jedis at version 8.0.1, start a server with docker run -p 6379:6379 -it redis:latest, then build a RedisClient against localhost:6379 and issue commands.

How it compares

This registry provides no list of paid products that Jedis replaces, and it names no comparable Java Redis client as an alternative, so no comparison against those axes can be drawn from the facts given. On the evidence available, Jedis stands alone in this registry as the Redis Java client entry, distinguished only by being maintained under the Redis organisation itself.

When to use it — and when not to

A self-hoster must operate a Redis server, whether via the documented docker run -p 6379:6379 redis:latest container or a managed instance; the library is a client and provides no database, no storage and no SMTP layer of its own. Teams needing object mapping, repository abstractions or Spring Data integration should not start here and should evaluate redis-om-spring instead, and anyone on a Redis version older than 7.2 will be outside the support envelope documented for current releases. Honest caveats: the README excerpt available here is truncated mid-topic on VectorSets, so feature documentation for newer data types must be read upstream, and the repository carries 125 open issues, which is normal for a client tracking a fast-moving server but still means reports can sit unresolved.

project readme (upstream, from github) — read inline

Jedis

Release Maven Central Javadocs MIT licensed codecov Discord

What is Jedis?

Jedis is a Java client for Redis designed for performance and ease of use.

Are you looking for a high-level library to handle object mapping? See redis-om-spring!

How do I Redis?

Learn for free at Redis University

Try the Redis Cloud

Dive in developer tutorials

Join the Redis community

Work at Redis

Supported Redis versions

The most recent version of this library supports redis version 7.2, 7.4, 8.0, 8.2, 8.4, 8.6, 8.8 and 8.10.

The table below highlights version compatibility of the most-recent library versions with Redis and JDK versions. Compatibility means communication features, and Redis command capabilities.

Jedis version Supported Redis versions JDK Compatibility
3.9+ 5.0 to 6.2 Family of releases 8, 11
>= 4.0 Version 5.0 to 7.2 Family of releases 8, 11, 17
>= 5.0 Version 6.0 to current 8, 11, 17, 21
>= 5.2 Version 7.2 to current 8, 11, 17, 21
>= 6.0 Version 7.2 to current 8, 11, 17, 21
>= 7.0 Version 7.2 to current 8, 11, 17, 21
>= 8.0 Version 7.2 to current 8, 11, 17, 21, 25

Getting started

To get started with Jedis, first add it as a dependency in your Java project. If you're using Maven, that looks like this:

<dependency>
    <groupId>redis.clients</groupId>
    <artifactId>jedis</artifactId>
    <version>8.0.1</version>
</dependency>

To use the cutting-edge Jedis, check here.

Next, you'll need to connect to Redis. Consider installing a redis server with docker:

docker run -p 6379:6379 -it redis:latest

You can instantiate a RedisClient like so:

RedisClient jedis = RedisClient.builder().hostAndPort("localhost", 6379).build();

Now you can send commands:

jedis.sadd("planets", "Venus");

Connecting to a Redis cluster

Jedis lets you connect to Redis Clusters, supporting the Redis Cluster Specification. To do this, you'll need to connect using RedisClusterClient. See the example below:

Set<HostAndPort> jedisClusterNodes = new HashSet<HostAndPort>();
jedisClusterNodes.add(new HostAndPort("127.0.0.1", 7379));
jedisClusterNodes.add(new HostAndPort("127.0.0.1", 7380));
RedisClusterClient jedis = RedisClusterClient.builder().nodes(jedisClusterNodes).build();

Now you can use the RedisClusterClient instance and send commands like you would with a standard pooled connection:

jedis.sadd("planets", "Mars");

Support for Redis data types

Jedis includes support for all Redis data types and features such as JSON and VectorSets.

Failover

Jedis supports retry and failover for your Redis deployments. This is useful when:

  1. You have more than one Redis deployment. This might include two independent Redis servers or two or more Redis databases replicated across multiple active-active Redis Enterprise clusters.
  2. You want your application to connect to one deployment at a time and to fail over to the next available deployment if the first deployment becomes unavailable.

For the complete failover configuration options and examples, see the Jedis failover docs.

Token-Based Authentication

Jedis supports Token-Based authentication (TBA) starting with 5.3.0 GA release. This feature is complemented by an extension library that enhances the developer experience and provides most of the components required for TBA functionality.

Notably, the extension library includes built-in support for Microsoft EntraID, offering a seamless integration as part of the generic solution.

For more details and examples, please refer to the Advanced Usage documentation.

Documentation

The Jedis documentation site contains several useful articles for using Jedis.

You can also check the latest Jedis Javadocs.

Some specific use-case examples can be found in redis.clients.jedis.examples package of the test source codes.

Troubleshooting

If you run into trouble or have any questions, we're here to help!

Hit us up on the Redis Discord Server or Jedis GitHub Discussions.

Contributing

We'd love your contributions!

Bug reports are always welcome! You can open a bug report on GitHub.

To report a security vulnerability, please follow our Security Policy.

You can also contribute documentation -- or anything to improve Jedis. Please see contribution guideline for more details.

License

Jedis is licensed under the MIT license.

Sponsorship

Redis Logo

Frequently asked questions

Is jedis free to use?

jedis is open source under the MIT licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does jedis do?

Redis Java client

What is jedis written in?

jedis is primarily written in Java. Its source is publicly available at https://github.com/redis/jedis, and it has 12,367 GitHub stars.