What does a machine read on a web page?
By Oliver Thompson, Analogue Media · Published · Checked · Markdown
¶6.1A machine reads the HTML a server sends: the text, the headings, the links, the alt text of images and any structured data. Some AI crawlers do not run JavaScript, so words that appear only after scripts run may never be seen by them. Colour, layout and animation are, for the most part, invisible to a machine.
¶6.2A 2024 study by Vercel and MERJ found that the crawlers OpenAI and Anthropic then used fetched JavaScript files but did not run them, while Google’s crawler did. The safe rule is that every word that matters should be in the HTML of the first response, before any script runs.
¶6.3Headings tell a machine what each part of a page is about, so a heading written as the question it answers is the most useful kind. Lists, tables and definitions are easy to lift whole. A picture is understood only through its alt text and its caption.
¶6.4Every word on this website is in the HTML when it arrives. Scripts add the demonstrations and the machine view, but with scripts turned off every answer, table and link is still there. The machine view, at the top of the page, shows roughly what a crawler keeps.