Page 20: WordPress has no Cache

WordPress is a great blogging platform and Content Management System, but I’ve read many times now each time a user hits one of your blog pages the database is queried up to 20 times (even if none of the content has changed since the last visit). Imagine what happens if your blog gets 1,000 unique users per day, or 10,000? WordPress has no Cache, but to solve this problem the WP-Cache plugin (or WP-Cache 2 now) was created. It creates a static HTML web page version of all your WordPress pages and “expires” them regularly for a new version – which takes the “database query” factor out of the equation when it comes to problems serving large amount of traffic and visitors through your WordPress blog. However, it’s recently come to my attention that WP-Super Cache works much better than WP-Cache, primarily because it doesn’t invoke PHP each time a static page is served. It boasts serving in excess of 250,000 cached pages per day. I highly recommend you read my post WordPress Hack #13: Traffic Proofing WordPress to read about other issues you should consider when using a WordPress caching plugin (like statistics or counting plugins being off), including fixes for some of them.

Also – as a side note, if you are an ‘advanced’ WordPress user – you may want to read WordPress 2.5 and the Object Cache.

As always – if you have a question, or something to add to this (20 page) article – please comment now below!

I would also recommend you take a look at my series 30 WordPress Hacks in 30 Days, and Managing WordPress More Effectively.