Ask HN: How can I trace what user queries make AI bots crawl my site?

1 ATechGuy 1 8/25/2025, 11:27:18 PM
I've noticed several AI bots crawling my website. Is there a way to figure out which specific user queries caused the AI to access my website?

Comments (1)

benoau · 4h ago
It might be present in your web server logs, with the caveat that you may not have them or have access to them and the bots may not pass the HTTP_REFERER header and the logs may not record it.

It might be present in client-side logs, with the caveat the crawler might block tracker URLs or not open a page in a way that executes their scripts.

Either of these may reveal what the first-page was a crawler reached, or the pages they directly-access without navigating your site.

You might be able to correlate timing for when a "user query" occurs and subsequent scraping.