Nailing Down Slow Performance in WordPress

Posted on August 11, 2010

I originally published this post this way back in may 2006. To date it is the most popular post on my site. Since then though a lot of tools have come out that make diagnosing a slow WordPress install a little easier. Here are sow updated tips that can help you get in the right direction.

Tip #1 – What Plugins are You Running?

My original post outlined how I had disabled all of my plugins and reverted my site back to the default WordPress theme to find out if the site would run fine at it’s basic level. From there I added plugins back one-by-one until I found which one slowed my site down. You can still troubleshoot it that way but there is an easier way.

Jason Jacobs linked to my original article from his article in which he had learned how to use Firebug, a Firefox/IE browser plugin, to find what plugin was slowing his site down. In Firebug their is an inspector that will tell you how long it is taking individual items to load. If there is is a plugin that is not optimized then it is probably going to stand out so you can see if their is an update or an alternative for it.

In my case when I originally wrote the article it was a LIghtbox plugin that slowing my site down. I deactivated the plugin and found another one that load quicker. Issue solved.

Here are links to Jason Jacobs article and the Firebug plugin:

Tip #2 – Cache Baby, Cache

The biggest strength and weakness of WordPress in my opinion is the that it is a completely database driven CMS. This is good in that only the parts of the site that you are editing get updated when you hit save unlike MovableType which has to rewrite ever page of the site. The downfall to being database driven is that ever time you load a page or post in your browser then the database needs to be queried in order to render the page.

Enter caching.

What caching does is make a temporary snapshot of each page and post of your site and gives that to your visitors instead of querying the database. This results in your pages and posts being served up much quicker and also reduces the load on your server. When you update a page the caching plugin automatically rewrites its copy so that your visitors get the newer version.

I have started to roll out caching on my WordPress sites and for some of my clients and I have to say that I have been impressed. There is a noticeable difference in how quick pages are loaded. This makes me especially happy since recently Google has stated that they are now going to incorporate page load times into the algorithm they use to determine search engine results. That means you can actually rank lower in search engine results if you site loads slowly.

The other benefit to caching is that if you get a large rush of traffic all of a sudden from a site like digg, Facebook, or Twitter. Without caching most shared hosting cannot query the database quick enough to WordPress show the message “Unable to Establish Database Connection” instead of your page or post. This can be a nightmare if you were trying to make affiliate or Adsense revenue off the page.

I personally use the WP Super Cache and I have been very happy with it. Note: Setup can be a little involved. Be sure to read the instructions carefully so that it is installed properly on your site.

Tip #3 – Who is Your Host?

You have scrubbed your plugins and they all load around the same amount of time. You have installed the caching plugin and you saw a little improvement. Unfortunately though your site is still loading slow.

What could it be?

Your hosting.

I have been working with WordPress for around 5 years now and I have run it on a lot of different hosting companies. The reason for using different companies was that I had done all on my end for my sites to run good but their servers just could not keep up. From downtime to slowness I have seen a few not so good hosting companies out there.

The reason for the slowness of certain web hosting companies comes down to volume. They just have too may people/web sites on a single server. WordPress especially puts a load on MySQL servers as most people do not use caching. The only way to remedy this is to switch hosting companies.

Personally I have used Hostgator for the last 3 years and have been very happy with them.

Now before you think that I am saying that to get some affiliate dollars out you I am not. Notice that there is no link to Hostgator in this post. If you want to change to them Google them. It is just that I have been with bad hosts and Hostgator has been good to me.

From my experience here is a list of host that have not been so great running WordPress:

  • Godaddy – great for domain names but hosting is not so great
  • Network Solutions – not great for domain names or hosting IMO
  • Jodo Host – This is who I had before Hostgator. They are better now but still not as good as Hostgator

If you have tried the other too solutions above and still are having issue then I would check out a different hosting company.

Still Trying to Troubleshoot FeedWordPress Issues

Posted on July 8, 2009

defeatUnfortunately the last few updates to the FeedWordPress plugin have not fixed the issues that I have been having. What is going on is that the meta data is not being pulled in to the individual posts when automatically searching for feeds and therefore it is not linking back to the original post.

I have setup a test site with a fresh install of WordPress and the FeedWordPress plugin that is updating correctly so it looks like I may have to kill my main site and start from scratch. The good thing is that I will be able to keep all 300+ posts that the main site has by exporting and reimporting via the WordPress import/export mechanism. My plan is to export the content, delete all the WordPress files including themes and plugins, and delete the db. From there I will do a reinstall of everything with fresh files and cross my fingers that it will work. It seems extreme but it seems the only fix available.

Wish me luck!

Why I Really Like WordPress 2.8

Posted on June 22, 2009

I have been slowly updating the sites that run WordPress over the last week or so and have started to really love WordPress 2.8. The reason for this sudden burst of affection are a couple of new features that version 2.8 introduced.

wordpress-upload-themeThe first feature that I really like is the ability to upload themes and plugins via the WordPress interface. This has eliminated the need to break out Dreamweaver or another FTP program to get something uploaded to a site.  That is significant because I usually download plugins and/or themes to my desktop. If I have to upload either of them with FTP I have to put them in a particular folder and hopefully I already have the FTP info entered into my program. If not then I need to go through those steps. With the web based upload feature I can quickly upload in a few steps.

The other feature that I like is the built in code editing for themes and plugins. I know this feature has been around for a while but 2.8 added code highlighting. This makes it much easier to find and edit small items without having to break out an FTP program and code editor.

These two features have reduced the time that it takes me to do small edits and I am truly gratefully for them.

FeedWordPress – One Step Closer to Fixing My Problem

Posted on June 16, 2009

So I posted the issue that I am having about the automatic update not pulling in the meta data for each post over on the official FeedWordPress site. I haven’t received a reply yet but in all fairness it is a free plugin so I would not necessarily expect to get an answer.

With that I setup another site really quick with a fresh install of WordPress 2.8 and the 2009.0613 version of FeedWordPress. I then setup my Twitter RSS feed to populate it and low and behold the automatic update pulled in all of the necessary meta data and linked back to the original source. This means that there must be something screwy with my install of the plugin but I am not quite sure what it is.

My options at this point are:

  1. Uninstall the plugin and hopefully it will delete itself completely from my WordPress db and then reinstall it.
  2. Kill the whole WordPress DB , delete the plugin, reinstall WordPress and the Plugin, re-import all my posts, and reconfigure FeedWordPress.

I am really hoping that option 1 will work. I guess I will find out in the next day or so. I will update when I find out what it took to fix it.

FeedWordPress Problems – It’s Got to Be Me, Not You

Posted on June 16, 2009

I have been using the plugin FeedWordPress for quite a while now to aggregate all of the feeds for all on my sites together into a single feed. From there I take that feed and then repost it back on each site. This way I get some cool cross-pollination between all on my sites.

You can see the aggregated site at network.idano.net.

A while back the links on this main feed started to link back to itself as opposed to the original site that the post came from. I figured out after a while that if I manually updated the network site that the links would be OK. While this was a work around it wasn’t very cool because it was completely manual.

A couple of days ago the developer of FeedWordPress came out with an update and I was optimistic that it would solve my problem.

Unfortunately it did not.

So here I am now trying to figure out why these links work correctly when I manually update but do not when they update themselves automatically.

One thing that I noticed is that when I update automatically several custom fields are created for the individual post. They are not for the automatic posts. These custom fields are:

  • syndication_feed
  • syndication_feed_id
  • syndication_item_hash
  • syndication_permalink
  • syndication_source
  • syndication_source_uri

In that list the syndication_permalink is the items that links directly to the original post on the original site.

In reading throw the documentation on the FeedWordPress site there is a built in filter that is supposed to change the_permalink() to the_syndication_permalink(). There are only two reasons why I can think that this is not happening.

  1. The meta data is not being collected for each post when done automatically so if the fields are empty then it just uses the default the_permalink().
  2. The theme is somehow causing issues. Again, the data looks like it is not being collected so that may not be the issues.

In the mean time I have switched to the default Kubrick theme to see if that makes a difference.

Fixing FeedWordPress PermaLinks to the Original Website

Posted on March 8, 2009

feedwordpressWith the recent upgrade of the syndication plug-in FeedWordPress that I use on my network.idano.net syndication site the links on the articles were no longer linking back to the original website. A few people had noted this issue on the comments thread but no one provided any solutions. Because the network.idano.net website was linking back to itself I was not getting the SEO and cross linking advantage that was intended. In fact there was a possibility that I could be penalized because of duplicate content.

To fix the issue I deactivated and deleted the plug-in on my network.idano.net website and then re-uploaded the plug-in. This included the MagpieRSS-upgrade rss.php and rss-functions.php files that needed to be uploaded to the wp-includes folder as well. Once that was done I cleared the cache in my browser and re-activated the plug-in.

From there I did a test post and manually had the FeedWordPress plugin check for a new post from that site. The plugin found the post and when I checked the Permalink it linked back to the original website like it was supposed to. Unfortunately it did not update the previous posts.

To correct the rest of the posts I went into my syndicated site and deleted the posts that had the incorrect linking. From there I went in and had the plug-in update from all of the syndicated sites. It found all of the posts that I had deleted, added them, and properly linked them back to the original sites.

Problem fixed. Case closed :-) .

Making Links in Posts from iPhone in WordPress

Posted on October 1, 2007

In my last post I was complaining about not being able to add links to posts from my iPhone. I was thinking about it again this morning (among the other limitations of the iPhone) when I remembered “hey, I know HTML”. Yes, that is right, I can hand code the link (oh the horror!).

So here it goes, a link to somewhere – digg.com.

Wow, that was some work. I thing a popup would still be nice. The iPhone does support JavaScipt afterall.

Mobile Admin Plugin for WordPress is Awsome

Posted on September 27, 2007

It finally happened. Someone came out with a plugin so that you can comfortably blog from your iPhone. Jared Bangs and Dan Cameron put the work in and now I can finally blog from anywhere.

With the plugin I can assign categories, manage comments and a whole bunch of other things also. There are only 2 things that it does not do which I wish that it did. One is that I was I could insert links and two is that I wish I could insert pictures.

Oh well, this is version 1.0 so hopefully they can trick the iPhone into

Posting a Photo from the iPhone

Posted on September 18, 2007

photo.jpg

Well I found out the hard way that WordPress does not support posting photos via their post by email function.

I did a little searching and found the Postie plugin that allows you to do so ( sorry I cannot provide a link – the iPhone doesn’t have a way to do so).
Anyway, this is cool because now I can blog from anywhere.
Now to go get it setup on my other blogs…
- This was sent via my iPhone, please excuse any typos.

« Older Entries