That Plugin You Love Can Kill Your WordPress Site

That Plugin You Love Can Kill Your WordPress Site

Plugins are awesome. It’s that simple.

The reason WordPress users have a love affair with plugins is also simple: extensibility. There are virtually an unlimited number and variety of plugins that provide a site with amazing features. A handful of plugins can give a WordPress site power that would have been unheard of a few short years ago without a lot of custom programming.

What Is A Plugin?

A plugin is a piece of software that can be installed as part of a WordPress site to add or enhance functionality. The capabilities of plugins range from analytics to image management to security to disaster recovery and beyond. While plugins are not required, I’ve never seen an installation of WordPress that doesn’t have at least one plugin. Even an out-of-the-box installation of WordPress has a few plugins by default.

While some plugins require a fee, most are free or have a free alternative, making their use all the more attractive.

As far as acquisition and installation goes, WordPress has made the entire process virtually a one-click affair. Even the most computer illiterate person can find, install and manage WordPress plugins.

But there is a flip side.

The Flip Side Of Plugins

Remember when Uncle Ben told Peter Parker that “with great power comes great responsibility?”

He was talking about WordPress plugins.

Plugins can be very powerful and if that power isn’t harnessed correctly, the plugin can cause anything from minor headaches to total site outages.

This shouldn’t dissuade anyone from using plugins, but instead encourage everyone to carefully evaluate plugins before committing to them. When I am evaluating a plugin, I have two things that I consider; incompatibilities and unintended consequences.

Incompatibilities

Plugins are software. As a result, they can be buggy and even incompatible with other software. Even WordPress.

Fortunately, both WordPress and plugins can be identified by version numbers. Those version numbers can be used to check whether a specific version of a plugin requires a specific version of WordPress. After finding that a plugin is compatible with WordPress, you’ll need to be mindful about future updates because updating one may cause the other to become incompatible. I’ll address how to get around this later.

Other times, two plugins that work fine on their own may stop working as a result of being incompatible with each other. This type of incompatibility is harder to identify and resolve.

As an example, caching plugins are commonly guilty of not playing nice with other plugins. Caching plugins pre-generate static content so that WordPress doesn’t have to produce a dynamic page in real time for each visitor. By default, if 100 visitors go to a site’s home page, WordPress must process each of those requests individually, generating 100 copies of the same content. With a caching plugin, WordPress generates a static copy of the page upon the first visit and the subsequent 99 visitors simply read the static copy, relieving WordPress of the need to reprocess the page over and over. The demonstrable result is better performance in the form of faster loading pages.

Caching poses a problem for many plugins that require the “processing” part of the page delivery. For example, if a plugin generates and inserts content into a page based on geography or user preferences then that plugin will not function properly because the processing has been bypassed. In a best case scenario, the plugin simply won’t work, but in the worst case scenario the site may lock up.

Here at {Web.Search.Social}, we experienced some problems with our backup plugin BackupBuddy and our caching plugin WPTotalCache. We sorted them out, but it took a bit of elbow grease and duct tape.

Unintended Consequences

Unintended consequences may arise from plugins that perform actions that are not immediately visible. Their negative effects may go unnoticed until it’s too late.

Not too long ago, I experienced a problem with a plugin called Yet Another Related Posts Plugin (YARPP) that creates links to related articles. We found that YARPP was affecting our disaster recovery process. After doing some digging, we found that YARPP had changed the WordPress database. The change prevented us from restoring backups.

What does YARPP have to do with backups?

Absolutely nothing.

Hence the unintended consequence.

We ultimately decided not to use YARPP, but found that after uninstalling YARPP, the modifications it made were still in place. Even though YARPP no longer existed in our installation, its effects did.

We were able to perform some techno magical super mojo on the database to correct it, but that’s not something everyone can do.

I documented the problem and made the developer aware of it. They have indicated that a fix will be available in the future. But for now, users should be aware of the problem.

The lesson here is that you should use plugins wisely and should not assume that because you remove a plugin there aren’t any remnants of that plugin.

If you want to read my technical description of the problem, you can find it here.

Should You Use Plugins?

The short answer is, “Yes.” The more practical answer is, “How can you not?”

While WordPress is great on it’s own, plugins give the platform its kick. In fact, I’ve never seen a WordPress installation with no plugins. The goal should be to use plugins wisely.

I’m often asked, “How many plugins should I use?” There’s no magic number, but the practical answer is, “As few as you need and not one more.”

And don’t be afraid to change things up. The number of plugins used by this site changes all the time. We keep the ones that we like and eliminate the ones we don’t.

How Can You Be Better Prepared?

Use plugins from a trusted source.

WordPress has it’s own directory of plugins that are available with reviews by the WordPress community. These reviews can provide you with valuable feedback on the performance of a plugin. There are many more great sources for plugins, but you should be skeptical when you are outside of WordPress’ sandbox.

Check compatibility.

Be mindful that not all plugins are compatible with every version of WordPress. WordPress continuously updates its software and this may cause existing plugins to break unless that plugin has an update of its own. In the WordPress plugin directory, each plugin is listed with what versions of WordPress it is compatible with. You should check against this information before making any updates.

WordPress and plugins and themes. Oh, my.

Remember that themes are kind of like plugins. Themes give WordPress sites their appearance. They are managed entirely differently than plugins, but they have more in common with plugins than you might think. Some plugins may work perfectly with WordPress, but not with your theme.

You should check the compatibility of your plugin against WordPress and your theme.

Be engaged in the plugin community.

I know. It’s maddening to deal with plugin issues. Fortunately, the WordPress community is vast and chances are whatever you are trying to accomplish has been tried by somebody else.

Whatever problem you are experiencing has probably been resolved by someone out there so your first course of action should be to try to find a published solution instead of figuring it out your own.

Paid plugins mean support.

Be mindful that if you have a paid plugin, you may be entitled to support from the plugin creator. That means that you don’t have to sort out your issues on your own. Use that resource to preempt any problems.

Check the date.

In the WordPress plugin directory, plugins display a “last updated” date. If a plugin has not been updated in 3,456,234 days, then you should probably skip it because the developer is probably never going to make updates. While plugins are typically not updated on a daily basis, there should be a reasonably small amount of time between updates.

Watch out for performance hogs.

Some plugins work behind the scenes to produce their intended effect. Sometimes, that work may require an amount of resources that your hosting provider does not supply. Hosting companies such as Bluehost and Hostgator offer very low priced hosting packages but that means limited backend resources. I’ve seen many sites get shut down because a plugin has tapped out the processor or RAM of a given hosting package.

Disable. Disable. Disable.

When you just can’t find the source of a problem, you should resort to the the most common debugging tactic; disable all plugins and enable them one at a time to determine the source.

Enter stage right.

Finally, there is no substitution to having a staging version of your WordPress site. A site that is accessible to you alone that you can tinker with and test. Many WordPress hosting providers offer more than one hosted site as part of their packages. Use that to your advantage to test and try out plugins in a manner that is safe and detached from your live site.

Where Do You Go From Here?

Where you go from here is up to you. The sky is the limit. As long as you use good judgement.

Let me know in the comments if you have had plugin nightmares and what you did to resolve them.

Super Duper Last Minute Hold The Presses Update!

A few days ago, unrelated to the writing of this article, I told my friend, Lisa Gerber (Yes, I’m name dropping, deal with it) that the pagination on her blog wasn’t working. I could go to her archives, but not beyond page one. A few days later, she posted to Facebook and asked if anyone could give her any help getting the pagination working and someone recommended that she install a new pagination plugin.

This happened literally the night before this article published.

I told Lisa to check her plugins first to see if any were out of date, and if not, to selectively deactivate plugins to help identify the culprit.

As it turns out, the YOAST plugin was out of date. She did a one-click update and – holy cow! – the pagination worked again.

So what’s the lesson here?

I propose that when your WordPress site hits a snag, do not introduce anything new until you at least know the source of the problem. If you have 6 plugins and don’t know which is causing a problem, having 7 won’t help. Also, and this is a biggie, don’t do anything before you back up your WordPress site.

Last night I reminded Lisa that a unicorn dies every time WordPress is not backed up.

Fortunately, she knows her stuff and was way ahead of me on that.

For those of you that know Lisa, let it be known that she will be making another appearance on {Web.Search.Social} this Monday because…

Well, I’ll just leave you in suspense as to why.