Use Google analytics to track 404 pages

Source: Internet
Author: User
Tags add html page modify

The 404 page is the error page (404 HTTP Status Code) returned by the server when the visitor has entered the wrong address or visited the deleted page. This page does not provide any valuable information in addition to telling visitors that the page does not exist. Visitors may leave the site for this.

It is useful to know the information on 404 pages, to find out what visitors are looking for and to recommend them, to help add new content to the site and fix the problematic links. How do I use Google Analytics to track and display 404 pages? Google Analytics's official blog introduces an easy way to use Google Analytics to track 404 page errors on a site.

1. Add the Google Analytics tracking code of the website to 404 pages.

2. Modify the Google Analytics code for the 404 page to change the code to form:

<script type= "Text/javascript"
src= "Http://www.google-analytics.com/urchin.js" >
</script>
<script type= "Text/javascript" >
_uacct = "Xxxxx-x";
Urchintracker ("/404.html?page=" + _udl.pathname + _udl.search);
</script>

3. The report of the/404.html page can be viewed in the hot content report, including the URL address where the error occurred, and the page where the visitor was last visited (referral source). Through this information, you can check the relevant pages in time, modify the error link.

English original: tip:tracking 404 Pages



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.