There are times where you want to delete all database data.

Warning -
The flush command deletes ALL of the data in the database. This includes all data in memory and persisted to disk. We recommend that you backup your database before you flush the data.

flushall for Redis Cloud Databases

You can flush a database from the command line with the redis-cli command or with your Redis client.

To flush database data from the redis-cli, run:

redis-cli -h <hostname> -p <portnumber> -a <password> flushall


redis-cli -h -p 12345 -a xyz flushall