Skip to content

Write pages the assistant can quote

The assistant reads your pages in sections and answers from a few of them. Here's how to write pages so the right section gets picked and quoted.

5 min read
A long printed page cut into neat strips along its headings, with a few strips lifted out and set apart.

The assistant doesn't read your site the way a visitor does. It reads a cleaned-up copy of each page, cut into sections, and answers from a handful of those sections. A few writing habits make a big difference to what it can find and quote. For the full path from question to answer, see How TalkToMySites answers from your pages.

What the assistant actually reads

When a page is indexed, we fetch the HTML your server sends and strip out everything that isn't main content. That means navigation, the page header, footers, sidebars, forms, scripts, embedded frames and any element with the hidden attribute. What's left is the text of the page, up to 200,000 characters. A page with less than 40 characters left after cleanup is marked Skipped. The details are in Add your site.

Two things fall out of that.

  • Facts in the chrome don't count. If your opening hours only live in the footer, or your support email only lives in the sidebar, the assistant never sees them. Put them in the body of a page too, like a Contact or About page.
  • The crawler reads HTML, it doesn't run JavaScript. Text that only appears after a script loads it, and content inside a tab or accordion that's marked hidden in the HTML, is left out. A <details> block is fine: its text is in the HTML.

Pages are split at headings

Headings from h1 to h4 mark where one section ends and the next begins. Each section becomes one or more passages of a few short paragraphs. The heading is kept at the top of the section's first passage, so the model can see what that text is about.

For each question, we pass the best 4 passages to the model, usually no more than 2 from the same page. That's the whole budget.

So the goal is simple: for any question a visitor might ask, one passage should contain the full answer.

One topic per section

A section titled "Details" that covers delivery times, returns and warranty in one block is hard to match. A question about returns has to compete with text about delivery, and the passage that wins might cut off before the returns part.

Split it:

  • ## Delivery times
  • ## Returns
  • ## Warranty

Now a returns question lands on text that's only about returns.

Don't go too far the other way. A section of only a sentence or two gets merged with the one after it, so very short sections don't buy you anything. Aim for a heading and a paragraph or two under it.

Say the answer near the heading

Write the way you'd answer out loud. Lead with the fact, then explain.

Weak:

We want to make things as easy as possible for our customers, so our policy has been designed so that...

Better:

You can return any item within 30 days for a full refund. Start a return from your order page.

Long sections get split into more than one passage, and the answer might not land in the one that gets picked. Put it in the first sentence.

Use plain words your visitors use. If people ask "can I cancel anytime", a heading that says "Cancelling your plan" matches better than "Subscription lifecycle management".

Titles and descriptions help

Your page <title> is attached to every passage from that page when it's indexed, and your meta description is added to the first passage. A title like "Shipping and returns" helps every section on the page match those questions. A title like "Info" helps nothing.

Don't hide facts in images or tables

Images aren't read. Text baked into a graphic, a screenshot of a price list, or an infographic is invisible to the assistant, and so is the image's alt text. If a fact matters, write it in the page text as well.

Tables are read, but only as plain text, one row per line. The column headers end up on their own line, away from the values below them. A row like "Pro 2,000 Daily" means little without its headers. For anything visitors ask about directly, add a sentence that states it: "The Pro plan includes 2,000 pages per site."

Keep one page per fact

If your refund window is mentioned on the FAQ, the terms page, a product page and an old blog post, all four can match a refund question. With only 4 passages to work with, the model might get two that agree and one that's out of date. Then it either hedges or picks the wrong one.

Pick one page that owns each fact and write it fully there. Elsewhere, link to it instead of repeating it. Changed your prices? walks through cleaning up after a change like that.

Check your work

After you edit, click Re-crawl sitemap on your site page so the assistant reads the new version (see Keep answers up to date for the limits). Then ask the preview a question the section should answer and open Sources. If the right page is listed and the answer quotes your new wording, the section is doing its job. Test your assistant with ten questions has a quick routine for this.

More from the blog

Interlocking abstract blocks connected by thin lines, arranged around a central glowing cube.
Engineering5 min read

How TalkToMySites runs on Cloudflare

One Worker, a handful of bindings and no outside AI provider. A tour of the Cloudflare products behind TalkToMySites and what each one does.

A key resting in front of a closed gate, with a small glowing light on the gatepost.
Product5 min read

Why we ask you to verify your domain

Your site is indexed straight away, but the widget only answers visitors once you've proven the domain is yours. Here's what the step is and how it works.