How to Find and Fix Broken Links from Your Website

How to Find and Fix Broken Links from Your Website

If you are running a blog or a website owner, you would be familiar that one of your important priorities must be providing a wonderful User Experience (UX) to your audience. Unluckily, broken links are a significant inconvenience that can get in the way. If you want to keep your website in good health and user experience, you’ll ultimately have to deal with them. So we have decided to tell you how to find and fix broken links on your website.

Fix Broken Links

Broken links on your website mean the missing of internal or external resources. When this problem occurs, it can bring your site visitors a huge amount of trouble. This is the reason you need to act fast and fix the broken links.

Broken links are surely not good for your website but the process of finding and fixing them is much easier. You can easily get several free and paid tools online that can help you to solve this problem. The most efficient and convenient free tool we suggest is Google Analytics.

Fix Broken Links

The process of locating and fixing broken links with Google Analytics can be divided into two following steps:

Step 1: Generate a Report for Broken Links

Detecting broken links with Google Analytics needs two different procedures concerning internal and external links. We will start with the first one.

First, you have to find out how your website produces a broken link error page. You can simply do this by typing in a URL you know doesn’t exist on your website. In this way, you can easily find the relevant browser tab for the name of the error page that occurs.

404 error

Next, log into your Google Analytics account and then navigate to Customization > Custom Reports. Then, click the +New Custom Report button:

Google Analytics

Now, fill in the title of your preference under the General Information section. Then fill the following fields under Report Content as follows:

Type: Flat Table

Dimensions: select Page, Previous Page Path, and Page Title

Metrics: Unique Pageviews

Under Filters, exclude Previous Page Path. This guarantees that only broken internal links show up in the report. At last, include Page Title and add the name of the error page you found earlier in the Regex field. You can also directly fill in “404” as a general condition.

Fix broken internal links

Lastly, save the report. Now, when you open it again, you’ll see a complete record of all your website pages with broken internal links:

Find broken internal links

To find broken external links, the method is essentially the same. Though, you have to make some changes to the Dimensions field when generating a custom report, particularly by including the PageFull Referrer, and Page Title options:

Find broken external links

Once you’ve created both reports, you’ve successfully discovered all of the broken links on your website. Luckily, fixing them is an easier process.

Step 2: Fix the Broken Links

So now that you have found your website’s broken links, you can move to the next step of fixing them. The first step is with your website, and here you can easily change any broken URLs manually.

Nevertheless, this isn’t the solution to the complete problem, as there can be other sites sending traffic to your pages with broken links. If this is the case, you’ll need to edit these page URLs either through manual 301 redirects, or a plugin such as Redirection:

The above-mentioned plugin will make the procedure of finding your dead links and managing the redirection process simple.

Using the plugin, you can easily add a Source URL (the broken link) and Target URL (the desired destination). When you save the changes, the plugin will take care of the process when it comes to redirecting visitors.

Leave a comment