How to Recover (Lost) Traffic from ChatGPT?
You've probably used ChatGPT or another AI assistant and received a broken link in response. You click, and it returns a 404, or the page doesn't exist at all.
This isn't a coincidence, but rather a result of: language models are trained on historical data,language models can fabricate sources (so-called hallucinations).
And now the most important thing: if you understand that large language models are based on historical data, it becomes obvious that the sources they reference in their syntheses often no longer exist – because the website owner (e.g., you) decided to remove them.
The result? It's immense frustration for the user, and a huge loss for you, the website owner.
If a chatbot (e.g., ChatGPT) points to your website, but the provided address (URL) doesn't work, you're losing potentially valuable traffic.
How to get this traffic back?
The methodology described by Ryan Law (Content Marketing Director at Ahrefs) is simple but brilliant (P.S. What you'll find below is my variation of this methodology – a 1:1 translation of what Law proposes).
1. Filter your AI traffic in GA4
Go to GA4, click on the report: Acquisition -> Traffic Acquisition, then select: Session – Source/Medium and specify a variable, e.g., chatgpt, then add an additional dimension: Landing Page
2. Examine HTTP Statuses
Write a simple script in Google Apps Script that will return a response code for each URL.
3. Perform 301 Redirects
Redirect any URL that generates a 404 or 410 error to the best-matching page. Example: if AI often generates e.g. /shop/armchairs/, and in reality you have /shop/leather-armchairs/, set a 301 redirect to this page.
Code Smart Web
At CodeSmartWeb.co.uk, we design and develop powerful, scalable systems built on the Laravel PHP framework, tailored to your brand and growth goals. From interface to infrastructure, we handle the full software lifecycle—from UI design to DevOps deployment—delivering secure, performant platforms that convert.