Exclude internal traffic from Google Analytics 4
Goal: Prevent website activity caused by you, your employees, or contractors from influencing your Google Analytics data.
Desired Outcome: Ensure internal traffic doesn’t distort your metrics, maintaining clean and accurate data for informed decisions.
Prerequisites: A functioning Google Analytics 4 account set up for your website.
Importance: Internal traffic can significantly skew your analytics, potentially leading to misleading insights and poor business choices.
Location: Within your Google Analytics 4 account.
When to Perform: Initially, upon setting up your Google Analytics account. Repeat if you suspect internal traffic might be affecting your data.
Who’s Responsible: The person managing your website analytics (you, your employees, or contractors).
Steps:
- Log in to your Google Analytics account.
- Click “Admin”.
- Verify you’ve chosen the correct property (website) and select “Data Streams”.
- Select the website where you want to implement Google Analytics 4.
- Scroll down and click “Configure Tag Settings” under Google Tag.
- Under Settings, click “Show all”.
- Click “Define internal traffic”.
- Click “Create” to establish internal traffic rules.
- Name the rule “Internal traffic” and keep the default traffic_type value set to “internal.”
- Set the Match type to “IP address equals” and enter your IP address in the value field.
- If you’re unsure of your IP address, click “What’s my IP address?” for Google to display it.
- To exclude multiple IP addresses (e.g., colleagues or other devices), click “Add condition” and repeat steps 9-11.
- With internal traffic defined, proceed to create a filter to exclude it.
Activating the Internal Traffic Filter:
- Log in to your Google Analytics account.
- Click “Admin”.
- Under Data Settings, click “Data Filters”.
- You should see a pre-existing filter for internal traffic (created during Google Analytics 4 property setup). Ensure it’s in “testing mode”.
- If it’s not in testing mode, click the three-dot menu and select “Test filter”.
- Thoroughly test the filter. Filtering in Google Analytics 4 is permanent; once data is filtered, it’s gone forever.
- Head to Reports > Real-time.
- Click “Add comparison” followed by “Select dimension”. Search for and choose the Test data filter name.
- Click “Select dimension values”, choose “Internal Traffic”, and click OK.
- Verify the test filter is correct and click “Apply”.
- Open a new browser tab and visit your website.
- Return to the Google Analytics 4 Real-time report. You should see 1 user under the test data filter, indicating the filter is working.
- Click “Admin” again.
- Under Data Settings, click “Data Filters”.
- Click the three-dot menu and select “Activate filter”.
- Once activated, internal traffic will be successfully excluded from your Google Analytics 4 data.