Goal
Use Redis for caches, queues and sessions, use its built-in JSON, search and vector features, and know what changes for existing Redis 7.4 databases.Prerequisites
- A StackShift account
- Any Redis client library
Workflow
1
Create a database and choose Redis. New databases run Redis 8.10.
2
Connect with the
rediss:// connection string from the database page.3
Bind it to your app so
REDIS_URL is set for you, then test a real job, cache write or session, not only PING.Versions
- New databases run Redis 8.10.
- Redis 6, 6.2, 7, 7.2 and 7.4 are not offered for new databases. Asking for one returns an error that tells you to use 8.10.
- In the API, CLI and Terraform the engine is
redis.
Built in
Redis 8 includes features that used to need Redis Stack. They are already loaded; there is nothing to turn on.- JSON: store and update JSON documents with
JSON.SETandJSON.GET. - Search and query: secondary indexes, full-text search and vector similarity search with
FT.CREATEandFT.SEARCH. - Time series:
TS.ADDandTS.RANGEfor metrics and sensor data. - Probabilistic structures: Bloom and Cuckoo filters, Count-Min Sketch and Top-K, for example
BF.ADD. - Vector sets: store vectors and run similarity queries with
VADDandVSIM.
Vector search over hashes
Redis or Valkey
- Choose Redis when you want JSON, search, vector search, time series or Bloom filters in the same database as your cache and queues.
- Choose Valkey when you only need caching, queues, sessions and rate limits.
- Both speak the Redis protocol, use
rediss://URLs andREDIS_URL, and work with the same client libraries. - Licences: StackShift runs Redis 8 unmodified under the open-source AGPLv3 licence, and Valkey under the BSD licence. Connecting to either from your app does not change your app’s licence.
Standby
An optional standby with automatic failover is rolling out for Redis and Valkey databases on StackShift servers. If your database page doesn’t offer a standby, it isn’t switched on for your account yet. Standbys are not available for databases on your own servers. Turn it on from the database page or withPUT /api/v1/databases/{id}/standby and {"mode": "async"}; send {"mode": "off"} to turn it off. sync is not offered for Redis or Valkey. GET /api/v1/databases/{id}/standby shows its state (enabling, active, degraded, failing_over, disabling, disabled or failed), which server is serving (master: home or standby), how many failovers happened and when the last one was. The database needs a recent backup that passed its restore check first.
- The standby runs on another server. If the main server fails, the standby takes over in about 20 to 35 seconds.
- Your connection string and
REDIS_URLnever change; clients reconnect on their own. - When the failed server comes back, it rejoins as the standby. Switching back to the main server pauses writes for 1 to 3 seconds.
- If only the standby is lost, your database keeps accepting writes.
- Copying to the standby is asynchronous, so a failover can lose about the last second of writes after a crash, or up to about 5 seconds if the main server is cut off from the network.
- Each failover shows up in your operations events.
- The standby is billed hourly as a second database of the same size.
- While a standby is on, stopping the database is refused. Deleting the database turns the standby off first.
Existing Redis databases
Existing Redis 7.4 databases move to Redis 8.10 after this release, and we email you on the day. You do not need to change anything: your connection string, password andREDIS_URL stay the same.
- Every key, value and expiry time is copied and checked before the switch.
- For 1 to 5 minutes writes pause while reads keep working. Retrying a failed write after the window works.
- We keep your previous database read-only for 7 days in case anything needs to be rolled back.
Limits
- Redis has no connection pooler; clients keep their own connections.
- Redis is not eligible for SQL Import / Export.
Expected result
Your app reads and writes keys through its usual Redis client, and
MODULE LIST shows the JSON, search, time series and Bloom modules.Common failures
Related guides
Valkey
Valkey 9.0, a Redis-compatible key-value engine for caches, queues and sessions.
Create a database
Create a hosted or connected-node database with private, direct public, or StackShift tunnel access.
Database connections and tunneling
Use private, direct public, or StackShift tunnel endpoints with TLS and explicit client IP policy.
Back up and restore a database
Use durable recovery storage correctly and understand why backups are independent from portable SQL transfers.