Get started today!◦ Full contract buyout ◦ Up to $1,000 credit ◦ Free migrations
Chat with us
Home » Magento Guide » Magento Security Guide » Learn to Flush Redis Cache on Magento Store

Learn to Flush Redis Cache on Magento Store

Don’t let Redis clutter your Magento store’s cache. Follow our guide to flush Redis from CLI quickly and easily.

Get fast, reliable hosting for WordPress

Power your site with the industry’s fastest, most optimized WordPress hosting

Redis is commonly used on Magento stores for object caching and page caching.


To be able to clear Redis from CLI, you will need to make sure that SSH is enabled if you have your Magento store on a non-cloud server. If you have a Magento cloud server, then you can find the SSH credentials from the portal of your site.


CAUTION: Use caution when performing this operation since data will be cleared related to object and page caching on your site. If you are a Nexcess client, we recommend discussing other options with our support team before flushing your Redis database. You may contact them by email or through your Client Portal.


Identify the Redis connection details in the configuration file of your Magento store. If you need help locating this file, then please contact our support team.


Flush your cache using one of the below commands, but replace the angled brackets (<>) and everything between them with the indicated information that has been provided by support. If the first path is invalid, try the second. The correct path depends on your server type and various other factors.

Flush your cache using one of the below commands, but replace the angled brackets (<>) and everything between them with the indicated information. If the first path is invalid, try the second. The correct path depends on your server type and various other factors.

redis-cli -s /var/tmp/redis-multi__cache.sock flushall


redis-cli -s /var/tmp/redis-multi__cache.sock flushall async


redis-cli -s /var/tmp/redis-multi__cache.sock -n flushdb


redis-cli -s /var/tmp/redis-multi__cache.sock -n flushdb async


The Redis CLI will make clearing the Redis caching on your Magento store fast.

For 24-hour assistance any day of the year, contact our support team by email or through your Client Portal.

Ready to get started?

Get the fastest, most secure WordPress.org hosting on the market.

Additional resources

What is managed WordPress hosting? →

Get details and decide if managed WordPress hosting is right for you.

Must-have web development plugins to create WordPress websites at scale →

Explore the best web development plugins to enhance functionality, improve performance, and streamline your WordPress site.

A complete guide to WordPress shortcodes →

Shortcodes make life easier. Learn how to get started!