You're debugging a production issue at 2am. You fire up redis-cli and type KEYS *. 50,000 keys flood your terminal. Now you need to inspect one — so you copy a key name, type TYPE user:session:a1b2c3d4, then TTL user:session:a1b2c3d4, then HGETALL user:session:a1b2c3d4. You've typed the same key name five times and made a typo twice.
LazyRedis gives you a lazygit-style TUI that shows everything at once — no commands to remember, no copy-pasting key names.
- Features
- Installation
- Usage
- Keybindings
- Multi-Profile Config
- Supported Redis Types
- Project Structure
- Development
- Contributing
Keys are grouped by the : delimiter into a navigable folder structure. user:1:name, user:1:email, user:2:name becomes:
▶ user/ (3)
└─ ▶ 1/ (2)
├─ STR name
└─ STR email
└─ ▶ 2/ (1)
└─ STR name
enter— enter a folderbackspace— go up one levelesc— jump to rootdon a folder — delete all keys under that prefix (with count + confirm)
ctrl+space— toggle selection on any item (leaf or folder)J/K— extend range selection down / updwith items selected — batch delete everything selected at once
│● 3 selected (d=delete ctrl+space=toggle) │
│● ▶ cache/ (12) │
│● STR config:debug │
│ STR session:abc │
Store multiple Redis connections in ~/.config/lazyredis/config.json. Press p to switch profiles without restarting.
{
"profiles": [
{ "name": "local", "host": "127.0.0.1", "port": 6379, "color": "green" },
{ "name": "staging", "host": "staging.internal", "port": 6379, "color": "yellow" },
{ "name": "production", "host": "prod.internal", "port": 6379, "color": "red", "tls": true }
]
}Each profile gets a colour that's reflected in the active panel border.
Every mutation is available through modal dialogs — no commands to type:
n— create a new key (type picker: string / list / hash / set / zset)d— delete key (or folder, or batch selection) with confirmationR— rename keyt— set / remove TTLe— edit selected item (hash field, list element, zset score/member)a— add item to list / hash / set / zsetD— delete selected sub-item
String values are rendered contextually:
- Valid JSON → pretty-printed with syntax highlighting
- Binary / non-printable bytes → hex dump with offset + ASCII sidebar
- Plain text → shown as-is, paginated
y— copy the current key name to clipboardY/c— copy the current value (or selected sub-item) to clipboard
lazyredis --tls --tls-skip-verify
lazyredis --tls --tls-cert ./client.crt --tls-key ./client.key --tls-ca ./ca.crtTLS can also be toggled in the in-TUI connection settings modal (S key).
Configurable auto-refresh (off / 1s / 2s / 5s / 10s / 30s). Default is 2 seconds. Set it in the connection modal (S → Tab to Auto-refresh).
Press 2 for the Server tab — version, mode, role, uptime, memory, clients, cache hit ratio. Press r to toggle raw INFO output.
When Redis is unreachable, a clear warning overlay appears with the failed address and instructions. LazyRedis keeps retrying in the background — no restart needed when Redis comes back up.
brew tap sm010422/lazyredis
brew install lazyredisgo install github.com/sm010422/lazyredis@latestPre-built binaries for macOS (arm64 / amd64) and Linux (arm64 / amd64) are available on the releases page.
# macOS Apple Silicon example
curl -Lo lazyredis.tar.gz \
"https://github.com/sm010422/lazyredis/releases/latest/download/lazyredis_darwin_arm64.tar.gz"
tar xf lazyredis.tar.gz
sudo mv lazyredis /usr/local/bin/git clone https://github.com/sm010422/lazyredis.git
cd lazyredis
go build -o lazyredis .
sudo mv lazyredis /usr/local/bin/Requires Go 1.21+.
lazyredis # localhost:6379
lazyredis --host 192.168.1.10 --port 6380
lazyredis --pass mysecret --db 3
lazyredis --tls| Flag | Default | Description |
|---|---|---|
--host |
127.0.0.1 |
Redis host |
--port |
6379 |
Redis port |
--pass |
(empty) | Redis password |
--db |
0 |
Database number (0–15) |
--tls |
false |
Enable TLS |
--tls-skip-verify |
false |
Skip TLS certificate verification |
--tls-cert |
(empty) | Path to client certificate |
--tls-key |
(empty) | Path to client key |
--tls-ca |
(empty) | Path to CA certificate |
| Key | Action |
|---|---|
j / k |
Move cursor down / up |
enter |
Enter folder |
backspace |
Go up one level |
esc |
Go to tree root |
g / G |
Jump to top / bottom |
ctrl+d / ctrl+u |
Page down / up (10 items) |
| Key | Action |
|---|---|
ctrl+space |
Toggle selection on current item |
J / K |
Extend selection range down / up |
d |
Batch delete all selected items |
| Key | Action |
|---|---|
n |
New key (type picker) |
d |
Delete key / folder / selection |
R |
Rename key |
t |
Set / remove TTL |
y |
Copy key name to clipboard |
Y / c |
Copy value to clipboard |
| Key | Action |
|---|---|
tab / l |
Focus value panel |
h / shift+tab |
Focus key list |
J / K (value focused) |
Move sub-item cursor |
e |
Edit selected sub-item |
a |
Add item |
D |
Delete selected sub-item |
j / k (value focused) |
Scroll value |
| Key | Action |
|---|---|
/ |
Open search — fuzzy match across all keys |
enter |
Confirm (glob patterns * ? [ trigger server-side SCAN) |
esc |
Close search, return to tree |
| Key | Action |
|---|---|
p |
Switch connection profile |
S |
Connection settings (host / port / pass / db / TLS / refresh) |
[ / ] |
Switch database (db0–db15) |
r |
Refresh keys + server info |
: |
Run raw Redis command |
1 / 2 / 3 |
Tab: Keys / Server / Help |
? |
Help screen |
q / ctrl+c |
Quit |
On first run, LazyRedis creates ~/.config/lazyredis/config.json with a default local profile. Edit it to add more connections:
{
"profiles": [
{
"name": "local",
"host": "127.0.0.1",
"port": 6379,
"db": 0,
"color": "green"
},
{
"name": "staging",
"host": "staging.redis.internal",
"port": 6379,
"password": "stagingpass",
"db": 0,
"color": "yellow"
},
{
"name": "production",
"host": "prod.redis.internal",
"port": 6380,
"password": "prodpass",
"db": 0,
"tls": true,
"color": "red"
}
]
}Available colors: green, blue, red, yellow, purple, peach, teal, pink, or any hex code (#a6e3a1).
Press p in the TUI to open the profile selector and switch connections instantly.
| Badge | Type | View | Add | Edit | Delete sub-item |
|---|---|---|---|---|---|
STR |
String | ✅ JSON / hex / text | — | ✅ | — |
LST |
List | ✅ indexed rows | ✅ RPush | ✅ LSet | ✅ LRem |
HSH |
Hash | ✅ field/value table | ✅ HSet | ✅ HSet | ✅ HDel |
SET |
Set | ✅ sorted members | ✅ SAdd | — | ✅ SRem |
ZST |
Sorted Set | ✅ rank/score/member | ✅ ZAdd | ✅ ZRem+ZAdd | ✅ ZRem |
STM |
Stream | ✅ entry viewer | — | — | — |
JSON |
RedisJSON | ✅ JSON.GET | — | — | — |
VEC |
Vector Set | ✅ card count | — | — | — |
TS |
Time Series | ✅ TS.INFO | — | — | — |
lazyredis/
├── main.go
├── Makefile # lint / test / test-redis / build, same as CI
├── .golangci.yml
├── .goreleaser.yaml
├── .github/workflows/
│ ├── ci.yml # lint, tests (Linux + macOS, real Redis), build check
│ └── release.yml # tag → GoReleaser → Homebrew tap update
└── pkg/
├── config/
│ ├── config.go # CLI flag parsing
│ └── profiles.go # ~/.config/lazyredis/config.json (mode 0600)
├── redis/
│ └── client.go # all Redis operations
└── ui/
├── app.go # bubbletea root model + message loop
├── app_handlers.go # key handling per tab
├── app_commands.go # tea.Cmds that talk to Redis
├── app_view.go # header, tabs, status bar, help
├── key_tree.go # hierarchical key tree builder
├── panel_keys.go # left panel — tree nav, multi-select, search
├── panel_value.go # right-top — type-aware value viewer + hex dump
├── panel_info.go # right-bottom — metadata + command log
├── panel_server.go # server tab — Redis INFO
├── panel_pubsub.go # pub/sub tab — channels + live messages
├── modal.go # overlay dialogs (confirm, input, profile, connect)
├── overlay.go # ANSI- and wide-char-aware modal compositing
├── text.go # truncation and padding by terminal cell width
└── styles.go # Catppuccin Mocha palette + profile colors
Requires Go (version in go.mod) and, for linting, golangci-lint v2.
git clone https://github.com/sm010422/lazyredis.git
cd lazyredis
go run . # connects to 127.0.0.1:6379
make test # unit tests + client tests against in-process miniredis
make lint # go mod tidy check + golangci-lintmake test needs nothing else installed: every client test starts its own
miniredis. miniredis does not
implement everything (for example MEMORY USAGE and DB index limits), so the
same tests can run against a real server:
redis-server --port 6399 --save '' &
make test-redis REDIS_ADDR=127.0.0.1:6399 # uses DB 15 and flushes itCI runs lint, go test -race on Linux and macOS, the client tests against
Redis 7.4 and 8.2, and a GoReleaser snapshot build on every pull request.
Text in the UI is measured in terminal cells, not bytes: Hangul and CJK are
two cells wide and styled strings carry ANSI escapes. Use the helpers in
pkg/ui/text.go instead of slicing strings.
Contributions are welcome. Please open an issue first to discuss what you'd like to change, and run make lint test before sending a pull request.
- redis-tui — another Redis TUI in Go
- RedisInsight — official GUI client
- redis-cli — the original CLI
Built with Bubble Tea · If LazyRedis saves you time, consider giving it a ⭐
