You are previewing Advanced Web Metrics with Google Analytics™, Second Edition.
O'Reilly logo
Advanced Web Metrics with Google Analytics™, Second Edition

Book Description

Valuable tips and tricks for using the latest version of Google Analytics

Packed with insider tips and tricks, this how-to guide is fully revised to cover the latest version of Google Analytics and shows you how to implement proven Web analytics methods and concepts.

This second edition of the bestselling Advanced Web Metrics with Google Analytics is the perfect book for marketers, vendors, consultants, and Webmasters who want to learn the installation, configuration, tracking techniques, and best practices of Google Analytics.

  • Google Analytics is a free tool that measures Web site effectiveness and helps users better understand how web site performance; this book is a detailed usage guide written by one of the software's original creators

  • Explains what filters keep data accurate, how to measure Flash usage and tag for e-mail marketing, and what visitor segmentation provides the most useful feedback

  • Examines principles and practices of Web analytics, then shows how to use GA's reports and how to track dynamic Web pages, banners, outgoing links, and contact forms

  • Discusses advanced setups for configuring goals and filters, how to integrate GA with third-party systems, and how to leverage the new API

Advanced Web Metrics with Google Analytics, Second Edition is valuable for both novice and experienced users of Google Analytics.

Table of Contents

  1. Praise for Advanced Web Metrics with Google Analytics, Second Edition
  2. Copyright
  3. Acknowledgments
  4. About the Author
  5. Foreword
  6. Introduction
    1. Who Should Read This Book
      1. What You Will Learn
      2. What You Need
    2. What Is Covered in This Book
    3. GA IQ Coupon
    4. How to Contact the Author
  7. I. Measuring Success
    1. 1. Why Understanding Your Web Traffic Is Important to Your Business
      1. 1.1. Website Measurement—Why Do This?
      2. 1.2. Information Web Analytics Can Provide
      3. 1.3. Where to Start
      4. 1.4. Decisions Web Analytics Can Help You Make
      5. 1.5. The ROI of Web Analytics
        1. 1.5.1. How Much Should I Invest in This?
      6. 1.6. How Web Analytics Helps You Understand Your Web Traffic
      7. 1.7. Where Web Analytics Fits In
      8. 1.8. Where to Get Help
        1. 1.8.1. Resources Provided by Google (Free)
        2. 1.8.2. Non-Google Resources (Free)
        3. 1.8.3. Official Google Analytics Authorized Consultants (Paid)
      9. 1.9. Summary
    2. 2. Available Methodologies and Their Accuracy
      1. 2.1. Page Tags and Logfiles
      2. 2.2. Cookies in Web Analytics
      3. 2.3. Understanding Web Analytics Data Accuracy
        1. 2.3.1. Issues Affecting Visitor Data Accuracy for Logfiles
          1. 2.3.1.1. Dynamically Assigned IP Addresses
          2. 2.3.1.2. Client-Side Cached Pages
          3. 2.3.1.3. Counting Robots
        2. 2.3.2. Issues Affecting Visitor Data from Page Tags
          1. 2.3.2.1. Setup Errors Causing Missed Tags
          2. 2.3.2.2. JavaScript Errors Halting Page Loading
          3. 2.3.2.3. Firewalls Blocking Page Tags
          4. 2.3.2.4. Tracking Legacy Mobile Visitors
        3. 2.3.3. Issues Affecting Visitor Data When Using Cookies
          1. 2.3.3.1. Visitors Rejecting or Deleting Cookies
          2. 2.3.3.2. Users Owning and Sharing Multiple Computers
          3. 2.3.3.3. Latency Leaving Room for Inaccuracy
          4. 2.3.3.4. Offline Visits Skewing Data Collection
        4. 2.3.4. Comparing Data from Different Vendors
          1. 2.3.4.1. First-Party versus Third-Party Cookies
          2. 2.3.4.2. Page Tags: Placement Considerations
          3. 2.3.4.3. Did You Tag Everything?
          4. 2.3.4.4. Pageviews: A Visit or a Visitor?
          5. 2.3.4.5. Cookie Timeouts
          6. 2.3.4.6. Page-Tag Code Hijacking
          7. 2.3.4.7. Data Sampling
          8. 2.3.4.8. PDF Files: A Special Consideration
          9. 2.3.4.9. E-commerce: Negative Transactions
          10. 2.3.4.10. Filters and Settings: Potential Obstacles
          11. 2.3.4.11. Time Differences
          12. 2.3.4.12. Process Frequency
          13. 2.3.4.13. Goal Conversion versus Pageviews: Establishing Consistency
        5. 2.3.5. Why PPC Vendor Numbers Do Not Match Web Analytics Reports
          1. 2.3.5.1. Tracking URLs Missing PPC Click-throughs
          2. 2.3.5.2. Slow Page Load Times
          3. 2.3.5.3. Clicks and Visits: Understanding the Difference
          4. 2.3.5.4. PPC Account Adjustments
          5. 2.3.5.5. Keyword Matching: Bid Term versus Search Term
          6. 2.3.5.6. Google AdWords Import Delay
          7. 2.3.5.7. Losing Tracking URLs through Third-Party Ad Tracking Redirects
        6. 2.3.6. Data Misinterpretation: Lies, Damn Lies, and Statistics
      4. 2.4. Improving the Accuracy of Web Analytics Data
      5. 2.5. Privacy Considerations for the Web Analytics Industry
      6. 2.6. Summary
    3. 3. Google Analytics Features, Benefits, and Limitations
      1. 3.1. Key Features and Capabilities of Google Analytics
        1. 3.1.1. Standard Features
          1. 3.1.1.1. Full Campaign Reporting—Not Just AdWords
          2. 3.1.1.2. Advertising ROI—Integration with AdWords and AdSense
          3. 3.1.1.3. E-commerce Reporting
          4. 3.1.1.4. Goal Conversions (Key Performance Indicators)
          5. 3.1.1.5. Funnel Visualization
          6. 3.1.1.6. Customized Dashboards
          7. 3.1.1.7. Site Overlay Report
          8. 3.1.1.8. Map Overlay Reports
          9. 3.1.1.9. Cross Segmenting Drill-Down
          10. 3.1.1.10. Data Export and Scheduling
          11. 3.1.1.11. Date Range Slider
          12. 3.1.1.12. Site Search Reporting
          13. 3.1.1.13. Multiple Language Interfaces and Support
          14. 3.1.1.14. High Scalability
          15. 3.1.1.15. Multiline Graphing
          16. 3.1.1.16. Administrator and Individual Access Controls
        2. 3.1.2. Advanced Features
          1. 3.1.2.1. Advanced Segmentation and Advanced Table Filtering
          2. 3.1.2.2. Secondary Cross-Segmenting Drill Down
          3. 3.1.2.3. Motion Charts
          4. 3.1.2.4. API and Developer Platform
          5. 3.1.2.5. Analytics Intelligence
          6. 3.1.2.6. Mobile Reporting
          7. 3.1.2.7. Pivot Views
          8. 3.1.2.8. Custom Reports
          9. 3.1.2.9. Benchmarking Reports
          10. 3.1.2.10. Event Tracking
        3. 3.1.3. Did You Know...?
      2. 3.2. How Google Analytics Works
      3. 3.3. What Google Analytics Cannot Do
        1. 3.3.1. Data Reprocessing
        2. 3.3.2. Bid Management
        3. 3.3.3. Non-Real-Time Reporting
        4. 3.3.4. Importing Third-Party Cost Data
        5. 3.3.5. Per-Visitor Tracking (against Google Policies)
      4. 3.4. Google Analytics and Privacy
        1. 3.4.1. Common Privacy Questions
      5. 3.5. How Is Google Analytics Different?
        1. 3.5.1. Targeting Digital Marketers Rather Than IT Departments
      6. 3.6. What Is Urchin?
        1. 3.6.1. Differences between Google Analytics and Urchin
        2. 3.6.2. Criteria for Choosing between Google Analytics and Urchin
      7. 3.7. Summary
  8. II. Using Google Analytics Reports
    1. 4. Using the Google Analytics Interface
      1. 4.1. Discoverability and Initial Report Access
      2. 4.2. Navigating Your Way Around: Report Layout
        1. 4.2.1. Dimensions and Metrics
        2. 4.2.2. Date Range Selector
        3. 4.2.3. Changing Graph Intervals
        4. 4.2.4. Changing Table Views
        5. 4.2.5. Moving through the Data
        6. 4.2.6. Table Filters
        7. 4.2.7. Tabbed Report Menus
        8. 4.2.8. Segmentation View
        9. 4.2.9. Chart Options
        10. 4.2.10. Export and Email Features
        11. 4.2.11. Chart Display and Annotation
        12. 4.2.12. Secondary Dimensions
        13. 4.2.13. Table Sorting
      3. 4.3. Summary
    2. 5. Reports Explained
      1. 5.1. The Dashboard Overview
      2. 5.2. The Top Reports
        1. 5.2.1. Intelligence Report
          1. 5.2.1.1. Intelligence Overview
          2. 5.2.1.2. Automatic Alerts
          3. 5.2.1.3. Custom Alerts
        2. 5.2.2. Visitors: Map Overlay
        3. 5.2.3. Ecommerce: Overview Report
        4. 5.2.4. Motion Charts
        5. 5.2.5. Benchmarking Report
        6. 5.2.6. Goal and Funnel Reports
        7. 5.2.7. Traffic Sources: AdWords
        8. 5.2.8. Traffic Sources: AdWords Keyword Report
        9. 5.2.9. Traffic Sources: AdWords Keyword Positions Report
        10. 5.2.10. Content: Top Content Report
        11. 5.2.11. Content: Site Overlay Report
        12. 5.2.12. Site Search: Usage Report
      3. 5.3. Understanding Page Value
      4. 5.4. Understanding Data Sampling
      5. 5.5. Summary
  9. III. Implementing Google Analytics
    1. 6. Getting Up and Running with Google Analytics
      1. 6.1. Creating Your Google Analytics Account
      2. 6.2. Tagging Your Pages
        1. 6.2.1. Understanding the Google Analytics Tracking Code
        2. 6.2.2. Deploying the GATC
      3. 6.3. Back Up: Keeping a Local Copy of Your Data
      4. 6.4. Using Accounts and Profiles
        1. 6.4.1. Roll-up Reporting
        2. 6.4.2. Choosing between Roll-up Reporting and Multiple Profiles
      5. 6.5. Agencies and Hosting Providers: Setting Up Client Accounts
      6. 6.6. Getting AdWords Data: Linking to Your AdWords Account
        1. 6.6.1. Testing after Enabling Auto-tagging
      7. 6.7. Getting AdSense Data: Linking to Your AdSense Account
      8. 6.8. Common Pre-implementation Questions
      9. 6.9. Summary
    2. 7. Advanced Implementation
      1. 7.1. _trackPageview(): the Google Analytics Workhorse
        1. 7.1.1. Tracking Unreadable URLs with Virtual Pageviews
        2. 7.1.2. Tracking File Downloads with Virtual Pageviews
        3. 7.1.3. Tracking Partially Completed Forms with Virtual Pageviews
        4. 7.1.4. Virtual Pageviews versus Event Tracking
      2. 7.2. Tracking E-commerce Transactions
        1. 7.2.1. Capturing Secure E-commerce Transactions
        2. 7.2.2. Using a Third-Party Payment Gateway
        3. 7.2.3. Tracking Negative Transactions
      3. 7.3. Campaign Tracking
        1. 7.3.1. Tagging Your Landing Page URLs
          1. 7.3.1.1. Step 1: Tag Only What You Need
          2. 7.3.1.2. Step 2: Use Google's URL Builder (tinyurl.com/urlbuilder)
        2. 7.3.2. Tagging Banner Ad URLs
        3. 7.3.3. Tagging Email Marketing Campaigns
        4. 7.3.4. Tagging Paid Keywords
        5. 7.3.5. Tagging Embedded Links within Digital Collateral
        6. 7.3.6. Creating Custom Campaign Fields
      4. 7.4. Event Tracking
        1. 7.4.1. Setting Up Event Tracking
          1. 7.4.1.1. The _trackEvent Function
          2. 7.4.1.2. Defining Your Event-Reporting Structure
          3. 7.4.1.3. Defining Categories
          4. 7.4.1.4. Defining Actions
          5. 7.4.1.5. Defining Labels—Optional
          6. 7.4.1.6. Defining Values—Optional
        2. 7.4.2. Tracking Flash Events
          1. 7.4.2.1. Using Legacy ActionScript 2
          2. 7.4.2.2. Using ActionScript 3
          3. 7.4.2.3. Event Tracking for Flash Professionals
        3. 7.4.3. Tracking Load-Time Events
        4. 7.4.4. Tracking Banners and Other Outgoing Links as Events
        5. 7.4.5. Tracking Mailto: Clicks as Events
      5. 7.5. Customizing the GATC
        1. 7.5.1. Subdomain Tracking
        2. 7.5.2. Multiple Domain Tracking
          1. 7.5.2.1. Method 1: Track a Visitor across Domains When Using a Link
          2. 7.5.2.2. Method 2: Track a Visitor across Domains When Using a Form
        3. 7.5.3. Tracking Visitors across Subdomains and Multiple Domains
        4. 7.5.4. Restricting Cookie Data to a Subdirectory
        5. 7.5.5. Controlling Timeouts
        6. 7.5.6. Setting Keyword Ignore Preferences
        7. 7.5.7. Controlling the Collection Sampling Rate
      6. 7.6. Summary
    3. 8. Best-Practices Configuration Guide
      1. 8.1. Initial Configuration
        1. 8.1.1. Setting the Default Page
        2. 8.1.2. Excluding Unnecessary Parameters
        3. 8.1.3. Enabling E-commerce Reporting
        4. 8.1.4. Enabling Site Search
          1. 8.1.4.1. Tracking Zero Results for Site Search
        5. 8.1.5. Configuring Data-Sharing Settings
      2. 8.2. Goal Conversions and Funnels
        1. 8.2.1. The Importance of Defining Goals
        2. 8.2.2. What Funnel Shapes Can Tell You
        3. 8.2.3. The Goal and Funnel Setup Process
          1. 8.2.3.1. Goal Details
          2. 8.2.3.2. Goal Name and Type
          3. 8.2.3.3. Defining Matches
          4. 8.2.3.4. Case Sensitive
          5. 8.2.3.5. Goal Value
          6. 8.2.3.6. Goal Funnel (Optional)
          7. 8.2.3.7. What Is a Required Step?
      3. 8.3. Tracking Funnels for Which Every Step Has the Same URL
      4. 8.4. Why Segmentation Is Important
      5. 8.5. Choosing Advanced Segments versus Profile Filters
      6. 8.6. Profile Segments: Segmenting Visitors Using Filters
        1. 8.6.1. Creating a Profile Filter
          1. 8.6.1.1. Filter Logic
        2. 8.6.2. Custom Filters: Available Fields
        3. 8.6.3. Five Common Profile Filters
          1. 8.6.3.1. Including Only Your Website's Traffic
          2. 8.6.3.2. Excluding Certain Known Visitors
          3. 8.6.3.3. What If Visitors Do Not Have a Fixed IP Address?
          4. 8.6.3.4. Segmenting by Geographical Location
          5. 8.6.3.5. Segmenting by Campaign, Medium, or Referrer Source
          6. 8.6.3.6. Segmenting by Content
        4. 8.6.4. Assigning a Filter Order
      7. 8.7. Report Segments: Segmenting Visitors Using Advanced Segments
        1. 8.7.1. Creating an Advanced Segment
          1. 8.7.1.1. Default Advanced Segments
          2. 8.7.1.2. Creating a Custom Advanced Segment
        2. 8.7.2. Example Custom Segments
          1. 8.7.2.1. Segmenting Mobile Phone Visits
          2. 8.7.2.2. Segmenting Social Network Visits
          3. 8.7.2.3. Grouping Visits from a Geographic Region
          4. 8.7.2.4. Segmenting Brand Visits
      8. 8.8. Summary
    4. 9. Google Analytics Hacks
      1. 9.1. Why Hack an Existing Product?
      2. 9.2. Customizing the List of Recognized Search Engines
        1. 9.2.1. Appending New Search Engines
        2. 9.2.2. Rewriting the Search Engine List
        3. 9.2.3. Capturing Google Image Search
      3. 9.3. Labeling Visitors, Sessions, and Pages
        1. 9.3.1. Implementing Custom Variables
      4. 9.4. Tracking Error Pages and Broken Links
      5. 9.5. Tracking Referral URLs from Pay-Per-Click Networks
      6. 9.6. Site Overlay: Differentiating Links to the Same Page
      7. 9.7. Matching Specific Transactions to Specific Referral Data
      8. 9.8. Tracking Links to Direct Downloads
      9. 9.9. Changing the Referrer Credited for a Goal Conversion
        1. 9.9.1. Capturing the Previous Referrer for a Conversion
        2. 9.9.2. Capturing the First and Last Referrer of a Visitor
      10. 9.10. Roll-up Reporting
        1. 9.10.1. Tracking Roll-up Transactions
        2. 9.10.2. Implications of the Roll-up Technique
        3. 9.10.3. Improvement Tip: Simplify with Pageview Roll-up
      11. 9.11. Summary
  10. IV. Using Visitor Data to Drive Website Improvement
    1. 10. Focusing on Key Performance Indicators
      1. 10.1. Setting Objectives and Key Results
      2. 10.2. Selecting and Preparing KPIs
        1. 10.2.1. What Is a KPI?
        2. 10.2.2. Preparing KPIs
      3. 10.3. Presenting Your KPIs
        1. 10.3.1. Presenting Hierarchical KPIs via Segmentation
        2. 10.3.2. Benchmark Considerations
      4. 10.4. KPI Examples by Job Role
        1. 10.4.1. E-commerce Manager KPI Examples
          1. 10.4.1.1. Average Conversion Rate
          2. 10.4.1.2. Average Order Value
          3. 10.4.1.3. Average per-Visit Value
          4. 10.4.1.4. Average Return on Investment
          5. 10.4.1.5. Customer on First Visit Index
        2. 10.4.2. Marketer KPI Examples
          1. 10.4.2.1. Percentage Brand Engagement
          2. 10.4.2.2. Conversion Quality Index
          3. 10.4.2.3. Average ROI by Campaign Type
          4. 10.4.2.4. Percentage of New versus Returning Visitors (or Customers)
        3. 10.4.3. Content Creator KPI Examples
          1. 10.4.3.1. Bounce Rate
          2. 10.4.3.2. Percentage Engagement
          3. 10.4.3.3. Average Time on Site and Pageviews per Visit
          4. 10.4.3.4. Advertisement Performance
          5. 10.4.3.5. Percent New versus Returning Visitors
          6. 10.4.3.6. Percent High, Medium, Low Visitor Recency
        4. 10.4.4. Webmaster KPI Examples
          1. 10.4.4.1. Volume of Visitors, Visits, and Pageviews
          2. 10.4.4.2. Percentage of Visits without English-Language Settings
          3. 10.4.4.3. Percentage of Visits Not Using Microsoft
          4. 10.4.4.4. Percentage Visits with Broadband Connection
          5. 10.4.4.5. Percentage of Error Pages Served
          6. 10.4.4.6. Internal Search Performance
          7. 10.4.4.7. Internal Search Quality
        5. 10.4.5. Using KPIs for Web 2.0
        6. 10.4.6. Why the Fuss about Web 2.0?
      5. 10.5. Summary
    2. 11. Real-World Tasks
      1. 11.1. Identifying and Optimizing Poorly Performing Pages
        1. 11.1.1. Using $ Index Values
          1. 11.1.1.1. Selecting Pages for Optimization
          2. 11.1.1.2. Exercises for Page Optimization
          3. 11.1.1.3. Summary of Methodology
        2. 11.1.2. Using Top Landing Pages (Bounce Rates)
          1. 11.1.2.1. Assessing Entrance Sources
          2. 11.1.2.2. Assessing Entrance Keywords
        3. 11.1.3. Funnel Visualization Case Study
          1. 11.1.3.1. Issues with the Funnel Presented
          2. 11.1.3.2. Action Points from the Funnel Visualization
          3. 11.1.3.3. Summary of Funnel Visualization
      2. 11.2. Measuring the Success of Site Search
      3. 11.3. Optimizing Your Search Engine Marketing
        1. 11.3.1. Keyword Discovery
          1. 11.3.1.1. Farming from Organic Visitors
          2. 11.3.1.2. Farming from Site-Search Visitors
        2. 11.3.2. Campaign Optimization (Paid Search)
          1. 11.3.2.1. Simplifying the Task
        3. 11.3.3. Landing-Page Optimization and SEO
          1. 11.3.3.1. Principles of SEO and Landing-Page Optimization
          2. 11.3.3.2. Summary of Landing-Page Optimization and SEO Techniques
        4. 11.3.4. AdWords Ad Position Optimization
          1. 11.3.4.1. Optimizing Positions by Visits
          2. 11.3.4.2. Optimizing Positions by Percent New Visits
          3. 11.3.4.3. Optimizing Positions by Per Visit Value
        5. 11.3.5. AdWords Day-Parting Optimization
        6. 11.3.6. Ad Version Optimization
      4. 11.4. Monetizing a Non-E-commerce Website
        1. 11.4.1. Approach 1: Assign Values to Your Goals
        2. 11.4.2. Approach 2: Enable E-commerce Reporting
          1. 11.4.2.1. Tracking a Non-E-commerce Site as Though It Were an E-commerce Site
          2. 11.4.2.2. Defining Your Pseudo E-commerce Values
          3. 11.4.2.3. Calling the Function _trackTrans()
          4. 11.4.2.4. Special Case: Pseudo E-commerce Fields for Multiple File Downloads
      5. 11.5. Tracking Offline Marketing
        1. 11.5.1. Using Vanity URLs to Track Offline Visitors
        2. 11.5.2. Using Coded URLs to Track Offline Visitors
        3. 11.5.3. Combining with Search to Track Offline Visitors
        4. 11.5.4. Summary and Case Study
      6. 11.6. An Introduction to Google Website Optimizer
        1. 11.6.1. AMAT: Where Does Testing Fit?
        2. 11.6.2. Choosing a Test Type
          1. 11.6.2.1. When A/B Experiments Are Appropriate
          2. 11.6.2.2. When Multivariate Experiments Are Appropriate
          3. 11.6.2.3. Use A/B Testing for Dynamic Content
        3. 11.6.3. Getting Started: Implementing a Multivariate Experiment
          1. 11.6.3.1. Step 1: Set Up a Test Page and Conversion Goal
          2. 11.6.3.2. Step 2: Install JavaScript Tags on Both Pages
          3. 11.6.3.3. Step 3: Create Alternative Variations to Test
          4. 11.6.3.4. Step 4: Review and Launch
          5. 11.6.3.5. How Long Will an Experiment Take?
        4. 11.6.4. Calyx Flowers: A Retail Multivariate Case Study
          1. 11.6.4.1. Results and Impact
        5. 11.6.5. YouTube: A Content-Publishing Multivariate Case Study
          1. 11.6.5.1. Results and Impact
      7. 11.7. Summary
    3. 12. Integrating Google Analytics with Third-Party Applications
      1. 12.1. Extracting Google Analytics Information
        1. 12.1.1. Importing Data into Your CRM Using JavaScript
        2. 12.1.2. Importing Data into Your CRM Using PHP
      2. 12.2. Working with the Google Analytics Export API
        1. 12.2.1. How to Use the Export API—the Basics
          1. 12.2.1.1. Authorization
          2. 12.2.1.2. Account Query
          3. 12.2.1.3. Report Query
        2. 12.2.2. Examples of API Applications
        3. 12.2.3. Example API Case Studies
          1. 12.2.3.1. Visual Basic Macros
          2. 12.2.3.2. VBA Usage Examples
          3. 12.2.3.3. Voice of Customer Integration
          4. 12.2.3.4. Excel Plug-in
          5. 12.2.3.5. Browser Toolbar
      3. 12.3. Call Tracking with Google Analytics
        1. 12.3.1. The CallTrackID Methodology
        2. 12.3.2. How CallTrackID Works
      4. 12.4. Integrating Website Optimizer with Google Analytics
        1. 12.4.1. The Integration Method
          1. 12.4.1.1. Generating Unique URLs for Each Multivariate Test
          2. 12.4.1.2. Viewing Test Alternatives in Google Analytics
      5. 12.5. Summary
  11. A. Regular Expression Overview
    1. A.1. Understanding the Fundamentals
    2. A.2. Regex Examples
  12. B. Useful Tools
    1. B.1. Tools to Audit Your GATC Deployment
    2. B.2. Firefox Add-ons
    3. B.3. Desktop Helper Applications
  13. C. Recommended Further Reading
    1. C.1. Books on Web Analytics and Related Areas
    2. C.2. Web Resources
    3. C.3. Blog Roll for Web Analytics