Originally at https://searchenginewatch.com/2016/02/11/fixing-404-error-pages-with-google-analytics/

There have been multiple blog posts written over the years on how to use Google Analytics to identify and fix 404 Error Pages.

I have even written one myself and it’s a common slide in many of my talks. But with the newest features that are available within Google Analytics, these blog posts are due an update.

Custom Variables vs Events

The first question is whether to capture details of the 404 Error Page within page level customisations or as an event.

My approach is to capture more information about the page using page level customisation. Since viewing a 404 Error Page is not an event, it should not be treated as one.

Google Analytics tracking

Step one in the GA tracking for Error Pages is to rename the page name to /error-page/404-error. This means all views of this page are grouped together, making them easier to identify and analysis becomes significantly easier.

There are two key pieces of information to capture on each 404 Error Page. The first is the URL of the page and the second is the referrer to the page.

Both are available as default Variables within GTM (Google Tag Manager) and so no developer support is required to capture them. The L3 Analytics approach is to capture the Page URL as a Content Grouping and the Referrer as either a Content Grouping or a Hit scoped Custom Dimension.

enabled built in variables

Previously I would have stopped at that tracking, but an Error Page view should now also be captured as a Custom Metric. It will provide an easy way to see the total number of Error Page views for the website or broken down by any session/user dimension.

Google Analytics configuration

Previously, we always recommended creating a Goal for View Error Page. It is useful to know if visitors are…

For Your Full SEO Site Report visit http://nationwideseo.com.au/site-report/