grpc.io
grpc.io copied to clipboard
Analytics: resolve redundant-hostnames warning
This is the warning
Property grpc is receiving data from redundant hostnames. Some of the redundant hostnames are:
- grpc.io
- www.grpc.io Redundant hostnames are counted as separate rows in reports, so hits that are going to the same page on your site from different hostnames will be split into multiple rows. With data split across multiple rows, traffic to specific pages will appear lower than it actually is.
To avoid this problem, consider setting up a 301 redirect from one of your redundant hostnames to the other, or create a search-and-replace filter that strips "www." from hostnames.
Google Tag Assistant Recordings can help you verify that your redirect is setup correctly, or that your filter is working as intended.
For details about filters, see Search-and-replace filters.
/cc @ejona86 @thisisnotapril
This might be an old message. I've selected "recheck".
Yep, this is still a problem, which can be confirmed by the fact that the www domain pages are served with status 200 not 301:
$ curl -i https://www.grpc.io 2>/dev/null | head -25 | grep ^H
HTTP/2 200
Note: drop the grep
to see the full response header.
This same problem shows up under GA4, unsurprisingly:
Here's what I'm getting now that #1052 has been merged and deployed:
$ curl -i https://www.grpc.io 2>/dev/null | grep '^[lH]'
HTTP/2 301
location: https://grpc.io/
$ curl -i https://grpc.io 2>/dev/null | grep '^[lH]'
HTTP/2 200
I've triggered a re-verification in GA:
Notification archived while verifying. Most checks verified within 24 hours, but some may take longer.
Nope, that didn't solve the problem. GA still reports redundant hostnames:
Redundant Hostnames
First detected: Jun 28, 2020, 2:19:44 PM Last detected: Sep 28, 2022, 1:08:36 AM
Property grpc - UA is receiving data from redundant hostnames. Some of the redundant hostnames are:
- grpc.io
- www.grpc.io
Redundant hostnames are counted as separate rows in reports, so hits that are going to the same page on your site from different hostnames will be split into multiple rows. With data split across multiple rows, traffic to specific pages will appear lower than it actually is.
To avoid this problem, consider setting up a 301 redirect from one of your redundant hostnames to the other, or create a search-and-replace filter that strips "www." from hostnames.
Google Tag Assistant Recordings can help you verify that your redirect is setup correctly, or that your filter is working as intended.
Learn more: https://support.google.com/analytics/bin/answer.py?answer=1034834&hl=en-US
The Tag Assistant link in that message is to the legacy version. Here are updated links:
- https://chrome.google.com/webstore/detail/tag-assistant-companion
- https://tagassistant.google.com
I've triggered a re-check again. Maybe I issued the re-check too earlier after the merge yesterday.