# jaredwray/keyv

Simple key-value storage with support for multiple backends

Repository: https://github.com/jaredwray/keyv
Canonical: https://ross.abutalabs.com/products/keyv
Homepage: https://keyv.org
Language: TypeScript
License: NOASSERTION
License Family: other
Topics: keyv, key-value, cache, etcd, memcache, mongo, mysql, postgres, redis, sqlite, storage
Last push: 2026-08-25T19:27:25+00:00

## Health v2 (maintenance only)
Score: 98/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 96, longevity 100
- inputs: {"age_days": 3344, "days_push": 8, "days_rel": 30, "gap_med": 10, "n_releases_24m": 56}
- flags: no_license
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 3187, forks 202 (observed 2026-08-28T04:07:48.057253+00:00)

## What it is
Keyv is a TypeScript key-value storage library providing a consistent interface across multiple backends via storage adapters (Redis, Postgres, MySQL, SQLite, MongoDB, Memcache, etcd, DynamoDB, Cloudflare KV, and in-memory). It supports TTL-based expiry, compression, serialization, and namespaces, making it suitable as a cache or persistent key-value store.

## Use cases
- add caching to a node.js app with redis or sqlite backend
- swap key-value storage backends without changing code
- store session data with ttl expiry
- cache api responses in express or fastify
- persist key-value data in cloudflare workers
- add cache support to my own npm module

## When to choose
- you need a unified key-value API across many storage backends
- you want TTL-based caching in Node.js or the browser
- you want to make your library's storage backend pluggable

## When to avoid
- you need complex queries, joins, or relational data
- you need a distributed cache with built-in eviction policies like a dedicated Redis deployment
- you are not in the JavaScript/TypeScript ecosystem

## Facets
- artifact type: library
- maturity: active
- function: caching, database, serialization, compression
- domain: databases, web-development, backend, developer-tools
- platform: bun, browser, cross-platform
- tags: key-value-store, storage-adapters, ttl, cache, redis, sqlite, monorepo, nodejs, typescript

## Member repositories
- jaredwray/keyv (main) score 98

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:07:48.057253+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T07:24:59.133993+00:00, confidence not recorded.
  - readme: https://github.com/jaredwray/keyv (fetched 2026-08-28T04:07:48.057253+00:00, sha 84dd1e066e22)
  - homepage: https://keyv.org (fetched 2026-08-29T09:39:14.176773+00:00, sha fd54892b1ed8)
  - site_page: https://keyv.org/docs (fetched 2026-08-29T09:39:14.179374+00:00, sha 0e669f3e84ba)
  - registry_npm: https://registry.npmjs.org/keyv (fetched 2026-08-29T09:39:14.184354+00:00, sha 60555e70c0fb)
  - site_page: https://keyv.org/releases (fetched 2026-08-29T09:39:14.181549+00:00, sha 9858d117e5b7)
- Data as of 2026-08-30T08:39:29.467469+00:00.
