Change the tracking code on your not found page so Analytics records the missing address and the page that linked to it. Review the list monthly, redirect old pages with a clear new home, and leave the rest.

A not found page that fills every day

A veterinary clinic's website was rebuilt in the spring, with new page addresses throughout. Since then, the not found page has appeared among its most viewed pages in Analytics every day.

Someone is following old links. The staff cannot tell which links, from which sites or to which old pages, because the report shows only that the not found page was viewed.

Each of those visits is a person who wanted something and got an apology instead. Many leave without trying again.

Why the report shows one row

On many sites, the server answers a missing address by redirecting the visitor to a single page, often called something like /page-not-found, and the tracking code there records only that page's address.

Every broken link therefore lands in Analytics as the same page. The address the visitor asked for is lost, and so is the page that sent them.

Where the server shows the not found page at the missing address instead, each broken address appears as its own row, scattered among the real pages and hard to pick out.

What the report needs to show

To fix broken links, you need four facts about each one:

The second decides the fix, and the standard reports do not pair it with the missing address: a link on your own site gets corrected, while a link on another site gets a redirect.

A small change to the tracking code

The classic tracking code includes a line that records the page view. On the not found page, that line can record an address of your own making instead of the real one.

Start it with a word no real page uses, such as /notfound/, then add the address the visitor requested and the address of the page that sent them. The code can read both from the browser.

For that to work, the server must show the not found page at the missing address, with a proper not found status, rather than redirecting elsewhere.

The status matters to search engines too. A missing page should answer with a not found status so they can drop it; a redirect to an ordinary page tells them something is still there.

Reading the report each month

Once a month, open the pages report and filter it for the word you chose. Each missing address appears with the page that sent the visitor, sorted by how often it happened.

Sort them into three groups: links on your own site, links on other sites, and visits with no referring page at all, which come from bookmarks, typed addresses or old emails.

Work from the top. A handful of addresses usually account for most of the visits, and the long tail of single visits can wait.

A worked example

An appliance parts supplier in Cranbrook sells washer, dryer and range parts over the counter and ships them from its online store. The store was rebuilt in the summer, and every part page received a new address.

After the tracking change, the report showed that most visits to the not found page came from a few sources.

Repair forums had years-old threads linking to old pages for common belts and igniters. A parts list emailed to repair shops used old addresses too, and two links in the store's own footer pointed nowhere.

The footer links were corrected first. Old part pages linked from the forums and the parts list got permanent redirects to their new pages, and the list went out again with new addresses.

Mistyped addresses and robots probing for login pages that never existed were left alone. A forum reader following a years-old link reaches the right part, and the redirects tell Google where each old page has moved.

Old pages worth a redirect

Redirect an old address when there is a clear new page for the same thing, and when other sites, emails or printed material still send people to it.

Use a permanent redirect, which tells browsers and search engines that the page has moved for good. Point each old address at its closest match, not at the home page.

Pointing every missing address at the home page looks tidy, but the visitor who wanted a dryer belt lands on a welcome message, and search engines may treat those redirects as missing pages anyway.

Addresses to leave alone

Typing mistakes that appear once, addresses with stray characters on the end, and robots trying login pages or scripts your site never had can all stay as they are.

Pages for things you no longer offer, with no close replacement, can also return not found. That is the honest answer, and it lets search engines drop them.

Links on your own site come first

When the referring page is on your own site, fix the link itself rather than adding a redirect. Old menus, footers, blog posts and downloadable PDFs are the usual hiding places.

Webmaster Tools helps as well. Open a missing address in its Crawl Errors report, and it shows the pages that link there.

The counter-case

Where a website has never been rebuilt or moved, the not found page may get only a few visits a month, mostly typing mistakes. An occasional look at the crawl errors in Webmaster Tools covers it.

The tracking change earns its place after a rebuild, a move to a new domain or a change of system, when every old link on the web points at an address that no longer exists.

Most sites go through one of those sooner or later. Adding the change as part of the rebuild is simpler than adding it once the not found page has filled up.

Tracking the not found page

  1. Check how the server shows missing pages, and stop any redirect.
  2. Return a proper not found status at the missing address.
  3. Change the tracking line on the not found page.
  4. Filter the pages report for your chosen word each month.
  5. Fix links on your own site at their source.
  6. Redirect old addresses still linked from other sites.
  7. Leave typing mistakes and robots alone.

Step one comes first because the rest depend on it. While the server redirects every missing address to one page, the tracking code never sees what the visitor asked for.

The change above assumes the classic ga.js code, and tracking code from the Urchin days still on the site shows how to spot the older urchin script and replace it.


Frequently asked questions

Why does Analytics show only one not found page?

Many servers redirect every missing address to a single not found page, so Analytics records that page's address and loses the one the visitor asked for.

What does the tracking change record?

The address the visitor requested and the page that linked to it, recorded under a made-up address starting with a word such as notfound, apart from real pages.

Should every broken link get a redirect?

No. Redirect old pages that have a clear new equivalent and still receive visits. Leave one-off typing mistakes, robots probing for login pages and pages with no replacement.

Why not redirect missing pages to the home page?

Visitors land on a welcome message instead of what they wanted, and search engines may treat those redirects as missing pages anyway. Point each one at its closest match.

How often should I read the report?

Once a month suits most small sites, and once a week for the first two months after a rebuild, while old links are still being followed.

Does Webmaster Tools show the same thing?

Partly. Its Crawl Errors report shows missing addresses that Google tried to fetch and the pages linking to them, but not visitors arriving from old bookmarks or emails.

West Coast Media Solutions Inc. provides web design, web development, hosting, digital marketing, and business consulting to organisations across Canada, drawing on more than twenty-five years in the field.

Not found page busy since the rebuild?

Tell us where the site lives, and we will set up the tracking change and say which old links deserve a redirect.

Start a Conversation