How Can We Help?
Redis Cache for WordPress
Do you want to speed up your WordPress server using caching? This article will explain how to do that using Redis.
Prerequisites
It is assumed that you already have a Redis server setup.
WordPress Configuration
To connect your Redis server to WordPress open the wp-config.php
and add the following:
define('WP_REDIS_HOST', '127.0.0.1'); // Replace with your address
define('WP_REDIS_PASSWORD', 'FOO'); // Replace with your password
define('WP_REDIS_PORT', 6379); // Replace with your port
define('WP_REDIS_DATABASE', 0); // Replace with your desired database index
define('WP_CACHE', true);
Once Redis is connected, you must install a plugin supporting Redis Caching.
In this article, we continue with Redis Object Cache (wordpress.org).
Once installed make sure to activate it, optionally, you can also enable automagic updates.
Navigate to Settings
– Redis
, validate that the Filesystem and Redis are green. Click Enable Object Cache
and you are all set.
One Response
Could you also check other Redis cache plugins like: W3 Total Cache or LiteSpeed Cache?