Server Flushdb
# Redis Flushdb Command
* (javascript:void(0);)
* (javascript:void(0);)
* (javascript:void(0);)
* (javascript:void(0))
Redis Tutorial
(#)
(#)
(#)
(#)
(#)
## Redis Commands
(#)
(#)
(#)
(#)
(#)
(#)
(#)
(#)
[Redis Pub/Sub](#)
(#)
(#)
(#)
(#)
(#)
(#)
## Advanced Redis Tutorials
(#)
(#)
(#)
(#)
(#)
(#)
(#)
(#)
[](#)(#)
(#)[](#)
In-depth Exploration
Data Management
Scripting Languages
Scripts
Web Applications and Online Tools
Programming
Computer Servers
Networking
AI Tools, Chatbots, and Virtual Assistants
Development Tools
Search
# Redis Flushdb Command
!(#)(#)
The Redis Flushdb command is used to clear all keys from the currently selected database.
### Syntax
The basic syntax of the Redis Flushdb command is as follows:
redis 127.0.0.1:6379> FLUSHDB
### Available Versions
>= 1.0.0
### Return Value
Always returns OK.
### Example
redis 127.0.0.1:6379> DBSIZE # Number of keys before flushing (integer) 4 redis 127.0.0.1:6379> FLUSHDB OK redis 127.0.0.1:6379> DBSIZE # Number of keys after flushing (integer) 0
!(#)(#)
AI is thinking...
[](#)(#)
(#)[](#)
[Byte Ark Coding Plan supports mainstream large models such as Doubao, GLM, DeepSeek, Kimi, MiniMax, etc., with official direct supply that is stable and reliable. Configuration guide Β₯9.9/month Activate now](https://maas.xfyun.cn/modelSquare?ch=maas_lm_l2E)
YouTip