How To Find And Fix Broken Links

How To Find And Fix Broken Links on your website so you can fix them now why do you want to fix them well for user experience finding a broken link that that results in a 404 error or a page that doesn’t load is not good it’s not a good user experience and also it’s a ranking factor in Google so if Google finds that you have a lot of broken links on your website

they’re not going to rank you highly because I know the user experience is not going to be great so they will rank you below a page that doesn’t have any broken links or any website issues so that’s one of the reasons we want to check for broken links and doing it

manually is nearly impossible unless you have a one-page website links are everywhere so you want to make sure that you have an audit may automated way of checking them and what we use is a plug-in called the broken link checker plugin and it scans your website on a schedule that you determine and it emails you and shows them

the WordPress dashboard what we’re broken links are and what they are so let’s install that plug-in right now and let’s see if we can find some broken links to install that we hover over plugins on the left and then click on add new

broken link checker install

we type in broken link checker in the search box and click on enter or press Enter it’s the very first one we see on the left by Janus we click on install now then we click on activate plug-in and the plug-in does two things right off the bat under settings it adds an entry called link checker and in your dashboard it also adds a little meta box

where it shows broken link information it’s going to be added to the very bottom so here’s the broken link checker box it says right now no broken links found no URLs in the work queue searching your blog for links so because we just installed this plugin it now has to go out and scan the website for broken links so it’s not gonna show instant results it has to scan your site first which takes a bit of time

broken link checker settings general

if we go over over settings and then click on link checker we can set some of the settings to configure it the way we want it in this box we said how many hours between link checks so what this plugin does that it keeps on checking the same links it checks all the links on your site because links break and we don’t know when they break

we usually know why it’s because we make a change but we weren’t on top of things enough to know what that change effected so we know why the links break well we don’t know when or where they’re broken so this link checker goes every 72 hours or whatever number you put in here is how often it checks all the links on your site

but keep in mind the less number of hours you have in here the more server resources are going to be used to check your links because it’s not an easy task that has to go through all the pages on your site every time to find a broken link

the default is 72 for most websites 72 will do if you have a high traffic website there’s a lot of people and having a couple broken links will have a serious negative impact and user experience and I want to set this to a lower number of hours maybe every 12 hours even but 72 hours is good enough for most websites and then in this section

you can check to get notifications of broken links and then you can set them to individual authors if you want as well you enter the email here or you leave this empty and you use the admitting the website under it says here settings and then general which is where you specify the admitting tweaks section you can apply custom formatting to broken links the reason you might want to do this is so people know in advance the link is broken so they don’t waste

their time clicking on it you can even remove broken links so if the fines AB link is broken you can edit the CSS you can just add a display:none command so the link disappears or even just remove the the the color and the underline so doesn’t look like a link anymore and then people won’t click on it until you fix it and then you can stop search engines from falling broken links as well is good

because you don’t want Google to find broken links so I often have this option selected I remove the broken link as well and then for the suggestions the plugin will suggest alternatives to the broken links so for example if you have an about page and the URL was your domain.com ford slash about but then for some reason

who knows why for some reason you changed it to your domain name.com forged slash about us so you change that URL and if that page was linked to from somewhere else on your site those links are not broken and this plug-in will determine that those are pretty similar about and about us and it will suggest that is a fix it will suggest changing those all those old links that went to be about that now

go to the about us and the broken link checker plugin also finds other errors on your site and if you want if you uncheck this box all the areas that have fine so be shown as broken links even though some of them won’t be so I usually keep this one checked and when you’ve done all these settings and you’re happy with what they are click on Save Changes at the bottom and

look for links

we have a few more tabs to go through at the top so at the top we have a tab called look for links in and here you specify where we’re gonna look for links that are broken so by default we have comments pages and posts selected if you have other fields in here that you know for a fact you add links to on a regular basis or that have links you’ll want to check those as well I don’t suggest that you go through and just blindly check all of them because the more pages it goes through the longer will take to check them all

the more server resources you’re going to use so for example if you know for a fact your contact forms do not have links in them don’t check that box just skip those in the skin and then you can also set different post statuses to be checked by default it only checks the published ones

but you can have it so it checks the scheduled draft pending and private so we’ll check all posts, not just the ones that are currently live on the site so when you’re happy with these settings just click on Save Changes I haven’t changed anything so I’m gonna not Save Changes

which links to check

this time and the next tab which links to check or click on there and we can specify wait which links to check I recommend you check all of these because you want to check links so we want to check all the links that we have however if you know that you don’t have an embedded Vimeo video you know you don’t have embedded Dailymotion videos you can uncheck those but if you know that you do have an embedded YouTube playlist make sure you check this so check the ones that are important to you

make sure you go through and check all the ones you want and then you can even exclude links that you don’t want to check so if the URL contains certain words like for example the soccer mom who knows it’s making up a word here but the URL contains soccer mom it’s not gonna check those links generally I don’t use the exclusion list because I want all links to be checked all the time because you just never know find and fix Broken Links & Redirections For WordPress

protocols and API

when they’re gonna break so after you’ve checked all the links you want to check to click on Save Changes protocols and API is just kept these as default unless you’re advanced do you know what you’re doing these ones

Advanced

just find the way they are in the Advanced tab the first option is if the link takes more than this number of seconds whatever you have in this box by default it’s 30 if the link destination takes longer than 30 seconds to load the plug-in will count it as a broken link find and fix Broken Links & Redirections For WordPress

even though it may not be broken that load time may just be a very slow website it may be a crashed website which is not a problem with the link it’s a problem with that website until the website is fixed I usually keep this at 30 the link monitor when you’re inside your dashboard if you check this box link checker will run all the time so for the dashboard widget that we saw at the very front you can select which user roles can see that widget quite a fall this editor and above you can set the gist administrator or you can just not have that widget

there in the email that they send out and in the report inside the link checker you will have these options for each link so you’ll be able to edit the URL just with a couple clicks of a button you can unlink it you can say that’s not broken you’ve made a mistake Mr. plugin you can dismiss it without new changes you can recheck it which is the case if there’s a link to an external site that’s down you can recheck that so the remaining options are fairly advanced

we’re going to go through them anyway the max execution time is when the broken link checker plugins scan your website this is the maximum amount of time four hundred and twenty seconds by default you can change it to whatever

you want but this is a maximum amount of time that the plug-in can search and parse your links on the back end and then we can set the server load limit it sorry to go back to max is your execution time I should keep it at the default at 424 the silver the server load limit we can set how intensive the server can be working before the plug-in shuts down so the plugin might have the server load because of something else but the plugin also takes resources

so if the server load hits for the plugin we’ll stop working until the server load goes below 4 again and the current load is point zero seven on this test site that gets zero traffic so it’s not hard to hit a serve a load of 4 if you have a busy website target resource usage this sets how much how many resources the plug-in can use by default

it said 25 which is just fine logging enables a log of what the broken link checker has checked and the results of that check so in the plugin in the dashboard it only shows the ones that are broken in the log it will show everything it will show everything that’s good everything that’s bad so you can enable that log

if you want it to or if you want to and then if you do enable that lock you want to set down below where that log lives so by default it lives in the broke link broken link checker plug-in folder with this file name so you can always go and look it up in there anytime

you want or you can set change this safe destination to save somewhere else this option at the bottom this is if you click this button right here it’s the same as the fur time you install the plugin it will delete everything in its database not in the WordPress database I would delete everything in the plugins database and then it will recheck

everything from scratch and that’s all the options for this plugin and if you made any changes here click on Save Changes if you didn’t just leave them the way they are and we will soon see oh we have some results already there we found 13 broken links on this site so far detected 99 unique URLs in 292 links and 13 of them are broken

so if we click on this link to see which links are broken it would take us to another page where it shows you all the broken links and it’s pretty self-explanatory again this is the link that’s broken what happens it’s a 404 and what’s the link text or is it an image and on the right-hand side

it shows you where that link liveso this first link that’s broken lives on the sample page import and if you go through this is actually a theme that used to be installed that’s no longer installed and all of the links are found inside of folders are not accessible by the public then

the content folders so all these broken links are irrelevant so I’m gonna actually dismiss all of them because they’re all not actual links on the site they’re links to a plugin or a theme that doesn’t exist anymore so I’m going to check this box and then click on dismiss and then click on apply and now there’s back to know broken links found and now I’ll go deal with that that that remnant of that theme and those broken links won’t appear again and that’s how we check for broken links and that’s how we deal with them when they’re found me

Comments are closed.