Broken Link Checker for WordPress

Notice: This plugin has been transferred to ManageWP. I am no longer working on it. Please direct any feedback to the new developer. See the plugin homepage for more information.

Sometimes, links get broken. A page is deleted, a subdirectory forgotten, a site moved to a different domain. Most likely many of your blog posts contain links. It is almost inevitable that over time some of them will lead to a “404 Not Found” error page. Obviously you don’t want your readers to be annoyed by clicking a link that leads nowhere. You can check the links yourself but that might be quite a task if you have a lot of posts. You could use your webserver’s stats but that only works for local links.

So I’ve made a plugin for WordPress that will check your posts (and pages), looking for broken links, and let you know if any are found.

Features

  • Detects links that don’t work, missing images, deleted YouTube videos and other problems.
  • Periodically checks links in posts, pages, comments, custom fields and the blogroll.
  • New and modified entries are checked ASAP.
  • Notifies you on the Dashboard if any problems are found.
  • Lets you edit all instances of a specific link at once.
  • Gives you a list of all links ever posted on your site, with the ability to search and filter it.
  • Lets you apply custom CSS styles to broken and removed links.
  • Highly configurable.

The broken links show up in the Tools -> Broken Links tab along. If any invalid URLs are found a notification will also show up on the Dashboard widget. To save screen real-estate, the widget can be configured to stay closed most of the time and automatically expand when broken links are detected.

Download

broken-link-checker.zip (412 KB)

    Requirements

    • WordPress 3.0 or later
    • MySQL 4.1 or later

    The current version of this plugin is only compatible with WordPress 3.0 and up. If you have an older version of WP, try one of the older releases. Specifically, version 0.8.1 is the last one that’s still compatible with the WP 2.8 branch, and version 0.4.14 is the last one compatible with WP 2.1 – 2.6.x.

    Installation

    Install “Broken Link Checker” just like any other WordPress plugin :

    1. Download the .zip file (see below).
    2. Unzip.
    3. Upload the broken-link-checker folder to you /wp-content/plugins directory.
    4. Activate the plugin in the Plugins tab.
    Related posts :

    2,584 Responses to “Broken Link Checker for WordPress”

    1. White Shadow says:

      It is wrapped with if(!function_exists()) calls, so I must say I’m quite confused by this error. See the relevant code fragment :

      if (!function_exists('json_encode')){
      	//Load JSON functions for PHP < 5.2
      	if (!class_exists('Services_JSON')){
      		require 'JSON.php';
      	}
      	
      	//Backwards compatible json_encode.
      	function json_encode($data) {
      	    $json = new Services_JSON();
      	    return( $json->encode($data) );
      	}
      }
    2. […] Broken-Link Checker […]

    3. […] keep them all up to date, especially if you’re changing categories, titles, etc. Download the broken link checker for this. You may be surprised at just how many dead links you have. Don’t forget to check […]

    4. mgomes says:

      Thks for your answer.

      In that case, there is no clue, from where the error is coming from?

    5. Hey Janis —

      Don’t know what you do on this last iteration of the plugin but it seems to work a LOT better now. The broken links really are broken! ๐Ÿ™‚ Thank you for your continued development!

    6. White Shadow says:

      @mgomes : I installed the latest version of the SimplePress forum to see what causes the problem, and I’m not getting the error you mentioned. Both plugins appear to co-exist peacefully.

      Do you have the latest versions of both the broken link checker and the forum plugin?

      @Dan : Ahha, thanks ๐Ÿ™‚

    7. Clay says:

      dude, this is an awesome plugin and pretty quick one if one know how to work with wordpress plugin. However, this plugin have quite a serious issue on the amount of resource it takes on the server which is not that good. Please look this up. Thanks ๐Ÿ™‚

    8. mgomes says:

      The error only happens when you post a topic to simplepress forum. that’s the only time.

      I’m using SPF 4.1 beta.

    9. White Shadow says:

      @ mgomes : Try installing the development version. I added a little workaround that may help.

      @ Clay : I’d be glad to reduce the resource usage, but I don’t see any easy ways to do that. If you have any practical ideas on how to improve the plugin’s performance, don’t hesitate to reveal them ๐Ÿ˜‰

    10. mgomes says:

      It’s working, the 2 plugins are now working peacefully ๐Ÿ™‚

      Thanks for this and keep up the good work in this really usefull plugin.

    11. Patti Meador says:

      Just installed the upgrade and if I try to run this along with WP Super Cache it makes my blog unusuable…can’t access home page or admin area. Have to disable BLC and WPSC by renaming folders in Cpanel (to disable both plugins) then I can enable one or the other, but not both. Enjoyed it while it lasted, but until this is fixed, I value WP Super Cache much more.

    12. White Shadow says:

      …this is bad, and I have no idea why it would happen. I’ll try to find out.

      Meanwhile, you could use one of the older versions of the plugin. The DB format should be backwards-compatible for all 0.5.x releases.

    13. White Shadow says:

      Patti, you could also try this modified version. I doubt it will help much, but it’s worth a try.

    14. Patti Meador says:

      Thanks White Shadow. I’ll go back to the older version for now. Loved the plugin and never had a problem with it (other than the occasional false report of a dead link) before the latest upgrade. I have another blog that does fine with the latest version (http://shop.bostonsandboxers.com/store) but I don’t run wp-super cache on that install.
      Thanks again for your help, and courtesy. I hesitated even reporting the issue as my previous experience w/plugin authors was less than pleasant. It’s nice to be treated with common courtesy ๐Ÿ™‚

    15. Hi
      I love your plugin. yes after i installed I found 18 broken link at essential page at my blog.so i can repair it.
      thanks
      I make simple tutorial rich with screenshoot at my plugin blog at http://www.pluginspecialist.com

      thanks

    16. Don’t be dumb with Broken Link Checker…

      If your blog rich ofย  links,ย  this Broken Link checker plugin is a must for you to prevent called “dumb” by visitor and never come back coz found one of your link not work well.
      By this plugin activated it will automatically test al…

    17. barronkid says:

      Sorry to be dense … I loaded the link checker and have assumed all was well until I found a broken link in my site … went back and the BLC said nothing about it. Upon further inspection I read the script’s output more carefully in the admin site, realizing that it isn’t telling me I have zero broken links … it says I have zero links!

      Specifically it says:
      No broken links found.
      No URLs in the work queue.
      No links detected.

      I searched the site for others who have experienced this phenomenon for some insight and direction, but couldn’t make any progress. Can you give me any advice on how to proceed in troubleshooting or checking the configuration more intensely?

      Thanks in advance!

    18. White Shadow says:

      That is most certainly a bug. Try this version of the plugin and run a re-check from the options page (and please report back if it works).

    19. Patti Meador says:

      I tried installing the older version of the plugin and got the same result (where it ran w/o a problem before). In order to access my bog’s dashboaed or homeage I had to rename BOTH plugin folders (BLC and WP-supercache) in order to deactivate the plugins and regain access. I don’t get it, but I can’t afford to keep crashing my blog. Thanks for trying ๐Ÿ™‚

    20. […] That plugins is Broken Link Checker […]

    Leave a Reply