I’ve been a longtime fan of WP Super Cache for WordPress. It works as advertised and significantly lowers page generation times and stress on your WordPress database. Today I compare it to a new caching plugin called DB Cache Plugin. It claims to be faster because it caches the php calls rather than the entire page. Do these claims hold water?
In order to run the test I added the follow code to the footer of my blog.
<!– <?php echo get_num_queries(); ?> queries. <?php timer_stop(1); ?> seconds. –>
This told me the number of database queries and time in seconds.
WP Super Cache vs DB Cache Plugin loading Turnipofpower.com
- WP-Super-Cache: 15 queries. 0.512 seconds
- DB Cache Plugin: 15 queries. 0.527 seconds
- No Caching plugin: 15 queries. 0.531 seconds
WP Super Cache vs DB Cache Plugin loading Turnipofpower.com with the Bad Behavior Plugin deactivated.
- WP-Super-Cache: 15 queries. 0.495 seconds
- DB Cache Plugin: 15 queries. 0.490 seconds
- No Caching plugin: 14 queries. 0.542 seconds
Conclusion: (please see updated note below) Both plugins performed similarly. Conducting these tests at 4:am, my blog traffic was minimal. At this time of night Bluehost is always fast, which is why the times without caching were so similar. I checked to make sure both plugins were operating properly. The DB-Cache plugin had cached files where they should be, and WP-Supercache displayed its proper “Cached page generated by WP-Super-Cache” message. What seems odd to me is that the DB Cache Plugin is supposed to lower the number of queries and it didn’t. On the positive side, the new contender worked fine with both my WordPress admin and the Bad Behavior plugin turned on. I’m hoping this plugin is updated soon fixing whatever issue prevents it from lowering the querie number. Anyone else giving the DB Cache Plugin a test?
*NOTE: These tests were performed using DB Cache version 0.2. I have now performed the tests again using version 0.3. See the results below:
DB Cache Plugin loading Turnipofpower.com with the Bad Behavior Plugin deactivated
DB Cache Plugin: 2 queries. 0.480 seconds
No Caching plugin: 15 queries. 0.489 seconds
That’s more like it. Database queries reduced from 15 queries down to 2 queries. This makes the plugin much more interesting, even if the actual load time isn’t dramatically different from super-cache. If anyone would like to try a follow-up test, please compare a blog running both WP Super Cache AND WP Widget Cache together vs this new plugin.
Plurk This Post
Buzz This Post
Delicious
Digg This Post
Ping This Post
Reddit This Post
Stumble This Post

It had problems on some sites and I’ve updated it to a new version 0.3. Could you please check it?
I wrote this plugin first of all for v.lviv.ua web-site, which has much dynamic widgets and that why I can’t use WP Super Cache. At the moment count of queries decreased from 150 to 2-5 for page
Nice improvement on version .3 of your plugin! The database queries were properly reduced from 15 to 2. I have updated my article to include the results of your latest version.
I get the following on my blog:
WP-Super-Cache: 22 queries 0,317 seconds.
No Caching: 22 queries 1,202 seconds.
I must mention that I use WP-Super-Cache with compression turned on. The load time has been cut to a quarter of what it was. I do not think that I need worry about anything else to try and get it better.
I am going to check out the DB Cache Plugin though.
Good point Lyndi, I neglected to mention I have compression disabled. Be sure to test the .3 version instead of the .2 version of DB Cache.
I tried the DB Cache plugin, but my page load time increased from 1.2 sec to 4-5 sec. The server average load also 5-doubled (see graphs and some further comments here:
http://www.marienblogg.no/2009/01/13/tester-cache-plugin/)
I’m curious as to whether I’m doing anything wrong, or if the plugin is braking with my blogg in some way..?
I’m not sure why the load would shoot up, unless you had two caching plugins running simultaneously? How was your page generation time and number of queries? Did that go up or down with the plugin activated? One thing I noticed about the plugin is that you have to go to the options and choose “disable” and save that setting to truly disable it. The author seems active in developing this plugin, so I expect frequent upgrades until all issues are resolved.
I have been thinking of such a plugin but since I have a dedicated server I have been putting it off.
Now, that I am changing providers and going back to a VM, I need to look at this. The VM is a temp thing until I get the new server configured and shipped to the new hosting provider.
So far, my dedicated server never reaches more than a 3% load on the server and the majority of the time it is less than 1%.
I think I will do some testing this week to see how much these plugins speed things up.
Just to be clear, with WP-Super-Cache, most requests are served directly by Apache from pre-rendered and pre-gzipped files, so 0 queries, 0 seconds spent in PHP = extremely fast w/ almost no CPU hit.
To notice the speed you must log out of your site because certain cookies will cause the URL rewriting to bail and the PHP version will be called. You also can’t look at stats embedded in the HTML to tell the story because that will be cached. Test with ab and you’ll see a dramatic boost in reqs/sec when WP-Super-Cache is set up correctly.
Yes, there’s room for improvement within PHP, so DB-Cache has it’s place (if it’s well-written–I’ve not tried it), but Super Cache works on another level, similar to how a reverse proxy cache works.
Just a fan.