Some websites return different HTML depending on the user agent that makes the request. If the Crawler's HTML is missing content you can see in your browser, the user agent may be the cause.
Before you start
- Open the URL Tester in the Crawler dashboard and run it on the affected page. The HTML tab shows exactly what the Crawler received.
- Rule out selector problems first. If the content is in the Crawler's HTML but isn't extracted, the cause is your selectors, not the user agent.
Test with different user agents
If the HTML itself is missing content, request the page with curl using different user agents and compare the responses:
# Default curl user agent curl http://example.com # The Crawler's user agent curl -H "User-Agent: Algolia Crawler" http://example.com # A regular browser user agent curl -H "User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:71.0) Gecko/20100101 Firefox/71.0" http://example.com
You can also use a browser extension that switches user agents. If the responses differ, your site is serving the Crawler something different from what it serves browsers.
What to do next
- Content missing for the Crawler only: Check whether your server, CDN, or security tool (for example Cloudflare or Google Cloud Armor) blocks or alters responses for "Algolia Crawler". Allowlist the Crawler's user agent or IP address. Allowlisting the IP is usually more reliable than matching the user agent.
- Content that needs JavaScript: Some sites send a robot user agent a simpler, JavaScript-free version of the page. This can work in your favor if the Crawler gets complete content that way.