CLIENT NO-TOUCH
CLIENT NO-TOUCH ON | OFF
- Group
- Connection
- Complexity
- O(1)
- Arity
- 3 (exactly, counting the command name)
- HotKV Cloud
- All plans
- On-Premise
- no license needed
With CLIENT NO-TOUCH ON, the commands this connection runs leave the keys’
last access time as it was. Use it for monitoring, auditing or backup tools
that read many keys: without it, their reads make cold keys look recently
used, which skews OBJECT IDLETIME and the
choices of an LRU or LFU maxmemory-policy.
OFF restores normal behaviour. While it is on, the connection shows the
T flag in CLIENT LIST.
Return value
Section titled “Return value”| Case | Reply (RESP2 and RESP3) |
|---|---|
ON or OFF |
Simple string OK |
| Any other value | Error ERR syntax error |
Examples
Section titled “Examples”127.0.0.1:6379> OBJECT IDLETIME report:2026-09(integer) 5400127.0.0.1:6379> CLIENT NO-TOUCH ONOK127.0.0.1:6379> GET report:2026-09"..."127.0.0.1:6379> OBJECT IDLETIME report:2026-09(integer) 5400Compatibility
Section titled “Compatibility”Same as Redis 7.2 and later, and Valkey 8. Unlike Redis, RESET does not turn it off.
See also
Section titled “See also”CLIENT NO-EVICT, OBJECT IDLETIME, TOUCH, memory and eviction
Was this page helpful?
Thanks for the feedback.