A particular URL that redirects, indicated by a 3XX HTTP status code, has nonetheless been recorded as having organic search traffic according to linked Google Analytics and Google Search Console data.
Why is this important?
Receiving traffic on a URL that should redirect searchers to the correct page indicates that the original, non-final URL is what’s showing in Google's index. Redirects don't provide a poor experience on the surface since users are routed correctly, but they do create additional delay, potentially impacting the speed at which content loads for the user.
What does the Optimization check?
The Optimization is activated for any internal URL that shows up with clicks in Search Analytics or visits in Google Analytics while also being set to redirect.
The information comes from Google Search Console and Google Analytics data accessed through an API for the associated Property/View within a chosen timeframe.
Examples that trigger this Optimization:
Take the URL: https://example.com/page-a which has accrued some search traffic.
This URL would cause the Optimization to activate if it presented a 301 (Permanent Redirect) HTTP response:
HTTP/... 301 (Moved Permanently)...
URLs indicating other types of 'redirect' HTTP status codes, essentially any in the 3XX range, would also trigger the Optimization.
How do you resolve this issue?
Firstly, consider that traffic data reflects past user interaction, whereas the crawl that detects the redirect status occurs immediately. Hence, the URL could have returned a HTTP Status 200 (OK) earlier before being redirected.
If this isn't the case, it's necessary to figure out why a redirecting URL is still indexed and attracting traffic. This could be due to Google not having re-crawled the URL yet, or potentially due to a range of factors that might make Google retain the URL:
Incorrect redirect setup, such as a loop.
Destination URL of redirect is not reachable or has issues (e.g. 404 error, disallowed by robots.txt).
Redirect destination URL pointing back to the original URL through a canonical link.
Redirecting URL still being referenced in an XML Sitemap.
Canonical tags on other URLs pointing to the redirecting URL.
Conflicting robot directives like 'noindex' or 'disallow'.
Achieving a consistent interpretation by Google can take some time if these factors are misaligned. Providing clear, unified signals can help Google understand which URL should be indexed and reduce confusion.