We took over a site written in WordPress recently, it was very, very slow. Ocassionally it took more than 10 seconds to load a page, normally after no one had visited the site for a while.
Here is what we did to change it from super slow, to super fast.
- Install WP Super Cache, make sure to enable it, and check that paths are SEO friendly, or it will not work
- Disable the way a default WordPress runs cron jobs. It intercepts the user hits from users, and do the tasks while the user is waiting. Obviously, that makes the site feel slow now and then: Find wp-config.php and add this line: define(‘DISABLE_WP_CRON’, true);
- Now setup a cron job calling the site regulary, like every 15 minutes, on a linux system the command is like this (replace yoursite.com with your site name):wget -q -O – http://yoursite.com/wp-cron.php?doing_wp_cron >/dev/null 2>&1
- Set preload to 60 minutes
Thats it, the site is now super fast 🙂