Documentation Index Fetch the complete documentation index at: https://mintlify.com/redis/redis/llms.txt
Use this file to discover all available pages before exploring further.
There are several ways to install Redis depending on your needs and platform.
Quick installation methods
If you want to get up and running quickly without building from source, use one of these methods.
Docker Fastest way to get started docker run -d -p 6379:6379 redis:latest
Package managers
Install Redis using your system’s package manager:
Homebrew (macOS)
Snap (Linux)
APT (Debian/Ubuntu)
brew install redis
brew services start redis
Package manager installations may not include the latest Redis features or modules. For access to all data structures and Redis Query Engine, build from source .
Docker installation
Redis provides official Docker images for both Alpine and Debian:
Run Redis in a container
docker run -d -p 6379:6379 --name my-redis redis:latest
Connect with redis-cli
docker exec -it my-redis redis-cli
Learn more about official Redis Docker images .
Build from source
Building Redis from source gives you access to all features, including JSON, time series, Bloom filters, and Redis Query Engine.
Building with BUILD_WITH_MODULES=yes enables all data structures and Redis Query Engine, but is not supported on 32-bit systems.
Select your platform for detailed instructions:
Ubuntu 24.04 Latest Ubuntu LTS with modern toolchain
Ubuntu 22.04 Ubuntu Jammy LTS release
Debian 11/12 Bullseye and Bookworm releases
macOS macOS 13 (Ventura) and 14 (Sonoma)
Ubuntu 24.04 (Noble)
Install dependencies
Update your package lists and install the necessary development tools: apt-get update
apt-get install -y sudo
sudo apt-get install -y --no-install-recommends ca-certificates wget \
dpkg-dev gcc g++ libc6-dev libssl-dev make git cmake python3 \
python3-pip python3-venv python3-dev unzip rsync clang automake \
autoconf libtool
Download Redis source
Download a specific version from GitHub (replace <version> with the desired version, e.g., 8.0.0): cd /usr/src
wget -O redis- < versio n > .tar.gz \
https://github.com/redis/redis/archive/refs/tags/ < versio n > .tar.gz
Extract the archive
cd /usr/src
tar xvf redis- < versio n > .tar.gz
rm redis- < versio n > .tar.gz
Build Redis with all modules
Set environment variables and compile: cd /usr/src/redis- < versio n >
export BUILD_TLS = yes BUILD_WITH_MODULES = yes \
INSTALL_RUST_TOOLCHAIN = yes DISABLE_WERRORS = yes
make -j "$( nproc )" all
The -j "$(nproc)" flag enables parallel compilation using all available CPU cores.
Run Redis
cd /usr/src/redis- < versio n >
./src/redis-server redis-full.conf
Ubuntu 22.04 (Jammy)
Install dependencies
apt-get update
apt-get install -y sudo
sudo apt-get install -y --no-install-recommends ca-certificates wget \
dpkg-dev gcc g++ libc6-dev libssl-dev make git cmake python3 \
python3-pip python3-venv python3-dev unzip rsync clang automake \
autoconf libtool
Install CMake
Install CMake using pip3 and link it for system-wide access: pip3 install cmake== 3.31.6
sudo ln -sf /usr/local/bin/cmake /usr/bin/cmake
cmake --version
CMake version 3.31.6 is the latest supported version. Newer versions cannot be used.
Download and build Redis
Follow steps 2-5 from the Ubuntu 24.04 instructions above.
Debian 11 (Bullseye) / 12 (Bookworm)
The Debian build process is identical to Ubuntu 22.04. Follow the Ubuntu 22.04 instructions above.
Tested with Docker images:
debian:bullseye
debian:bullseye-slim
debian:bookworm
debian:bookworm-slim
macOS 13 (Ventura) and 14 (Sonoma)
Install Homebrew
If Homebrew is not already installed, follow the installation instructions at brew.sh .
Install required packages
export HOMEBREW_NO_AUTO_UPDATE = 1
brew update
brew install coreutils make openssl llvm@18 cmake gnu-sed \
automake libtool wget
Install Rust
Rust is required to build the JSON module: RUST_INSTALLER = rust-1.80.1- $(if [ "$( uname -m )" = "arm64" ]; then \
echo "aarch64" ; else echo "x86_64" ; fi) -apple-darwin
wget --quiet -O ${ RUST_INSTALLER } .tar.xz \
https://static.rust-lang.org/dist/ ${ RUST_INSTALLER } .tar.xz
tar -xf ${ RUST_INSTALLER } .tar.xz
( cd ${ RUST_INSTALLER } && sudo ./install.sh )
Download Redis source
cd ~/src
wget -O redis- < versio n > .tar.gz \
https://github.com/redis/redis/archive/refs/tags/ < versio n > .tar.gz
tar xvf redis- < versio n > .tar.gz
rm redis- < versio n > .tar.gz
Build Redis
cd ~/src/redis- < versio n >
export HOMEBREW_PREFIX = "$( brew --prefix )"
export BUILD_WITH_MODULES = yes BUILD_TLS = yes DISABLE_WERRORS = yes
PATH = " $HOMEBREW_PREFIX /opt/libtool/libexec/gnubin: $HOMEBREW_PREFIX /opt/llvm@18/bin: $HOMEBREW_PREFIX /opt/make/libexec/gnubin: $HOMEBREW_PREFIX /opt/gnu-sed/libexec/gnubin: $HOMEBREW_PREFIX /opt/coreutils/libexec/gnubin: $PATH "
export LDFLAGS = "-L $HOMEBREW_PREFIX /opt/llvm@18/lib"
export CPPFLAGS = "-I $HOMEBREW_PREFIX /opt/llvm@18/include"
mkdir -p build_dir/etc
make -C redis-8.0 -j "$( nproc )" all OS=macos
make -C redis-8.0 install PREFIX= $( pwd ) /build_dir OS=macos
Run Redis
export LC_ALL = en_US . UTF-8
export LANG = en_US . UTF-8
build_dir/bin/redis-server redis-full.conf
Build flags and options
Redis supports various build flags to customize your installation:
Core build flags
All modules
TLS support
Systemd support
32-bit binary
make BUILD_WITH_MODULES=yes
BUILD_WITH_MODULES=yes enables JSON, time series, Bloom filter, cuckoo filter, count-min sketch, top-k, t-digest, and Redis Query Engine.
Build with all features
To build Redis with all data structures and TLS support:
export BUILD_TLS = yes BUILD_WITH_MODULES = yes \
INSTALL_RUST_TOOLCHAIN = yes DISABLE_WERRORS = yes
make -j "$( nproc )" all
Custom allocator
Redis uses jemalloc by default on Linux. To use a different allocator:
libc malloc
jemalloc (macOS)
Verbose build output
For detailed build information:
Testing your installation
After building Redis, test it to ensure everything works correctly:
Test TLS (if enabled)
If you built with TLS support: ./utils/gen-test-certs.sh
./runtest --tls
Requires tcl-tls to be installed.
Troubleshooting
Clean build
If you encounter build problems, perform a clean build:
This will clean jemalloc, lua, hiredis, linenoise, and other dependencies.
32-bit build issues
If you have problems building a 32-bit binary:
Install the package libc6-dev-i386 (also try g++-multilib)
Try using:
make CFLAGS="-m32 -march=native" LDFLAGS="-m32"
Switching architectures
If you need to switch between 32-bit and 64-bit builds:
Redis can be compiled and used on:
Linux (recommended)
macOS (supported)
OpenBSD, NetBSD, FreeBSD (supported)
Solaris-derived systems like SmartOS (best effort)
Redis supports both big-endian and little-endian architectures, and both 32-bit and 64-bit systems.
32-bit systems do not support BUILD_WITH_MODULES=yes.
Advanced: Intel SVS-VAMANA optimizations
For enhanced vector search performance with Redis Query Engine, you can enable Intel SVS-VAMANA optimizations (LeanVec and LVQ):
make BUILD_INTEL_SVS_OPT=yes
License Disclaimer : Intel SVS optimizations are not compatible with AGPLv3 or SSPLv1. They are only available for use with Redis Open Source when distributed under the RSALv2 license. See Intel SVS documentation for details.
Next steps
Quickstart Start using Redis with basic commands
Configuration Configure Redis for your needs
TLS Setup Run Redis with TLS encryption
Client Libraries Connect your application to Redis