SEO and AI Search 16 min read Published November 2026 By

How to Automate Keyword Clustering: From a Keyword List to an SEO Content Cluster

A brass machine on a workshop desk takes loose keyword cards, seo, automation, content, ai and tools, through a funnel and sorts them into three glowing groups. A conveyor carries out three folders labelled SEO cluster, automation cluster and content cluster, a chalkboard shows documents passing through a processor into three coloured groups, and an open notebook maps a topic cluster into one pillar page and two cluster pages, beside books on keyword research, clustering, topic models and content strategy.

Keyword clustering turns a long export of search phrases into the short list of pages a site should actually have, and it is the step that decides whether an SEO content cluster holds together or competes with itself. To automate it, let a model group the phrases by meaning, confirm the close calls against the results each phrase really returns, then check every group against the pages you already publish before anything is drafted. The machine does the sorting. A person decides which groups deserve a page, which one is the pillar, and which phrases belong to a page you already have.

From a keyword export to an approved cluster map

  1. 01ExportA long list of search phrases, hundreds of them
  2. 02Group by meaningA model embeds every phrase and groups the close ones
  3. 03Confirm close callsGroups near a boundary are checked against the results each phrase returns
  4. 04Check your pagesEvery group is matched to the page that already answers it
  5. 05Approved cluster mapA person decides which groups deserve a page, and the pillar
Fig 01 · The map comes before the draftsThe machine does the sorting, and the approved cluster map is the destination: a person decides which groups deserve a page and which one is the pillar before anything is drafted.

How to automate keyword clustering: what the job is

Automating keyword clustering means handing a script the dull half of SEO planning: reading hundreds of phrases, putting the ones a single page could answer into one group, and flagging the groups your site already covers. What comes out is not a list of articles. It is a cluster map, a table with one row per proposed page, which a person reads, edits and approves before a single brief is written. Everything after that, from the brief to the internal links, depends on that table being right. Packaging that work so it runs the same way every month, with its scripts, a table of the pages you own and the test cases that catch a bad merge, is the subject of our guide to building a keyword clustering engine in Claude Code.

What a cluster map holds, row by row

One row
One page you intend to have
Built for
The phrase the page is built for, and the other phrasings it absorbs
Intent
The intent the page serves
Already covered by
The page on your site that already covers it, if one does
Next
What happens next: a new page, a merge or a refresh
The map
A table a person reads, edits and approves before a single brief is written
Fig 02 · Not a list of articlesAutomating keyword clustering produces a cluster map, not a list of articles, and everything after it, from the brief to the internal links, depends on that table being right.

The map is the plan for an SEO content cluster, which is a pillar page on a broad subject surrounded by narrower pages that each answer one question inside it, all linked to each other. If the idea of a cluster is new to you, our guide to content clusters as the bridge between knowledge and content explains the pillar and its spokes from first principles, our page of SEO content cluster guides collects every article we have written on the subject, and the wider SEO and AI search guides put clusters beside the rest of search. This post covers the step those pieces assume has already happened: getting from a raw keyword list to groups that are worth building.

It matters because the expensive mistakes in a cluster are made here, not later. Two pages built for phrases that wanted one answer will split the clicks between them. A group that mixes a buying search with a learning search produces a page that serves neither reader. Google's own SEO Starter Guide suggests using directories to group similar topics so that a site is organised in a logical way, and a clean cluster map is what lets you do that on purpose instead of discovering the shape of your site after the fact. The topic-cluster prompt in our SEO content prompts asks a model to flag any two proposed pages that would compete for one search, which is the same check done by hand.

Two ways to group keywords: shared results or shared meaning

There are two honest ways to decide that two phrases belong together, and a good pipeline uses both. The first asks whether the two searches return the same pages, which is SERP overlap clustering. The second asks whether the two phrases mean the same thing, which is semantic keyword clustering, done with embeddings. The first is closer to the truth about intent and slower to get, and the second is fast and cheap and sometimes fooled by wording.

Shared results against shared meaning

Shared results only

  • Compares the top results each phrase returns
  • Needs result data from a licensed source or a person
  • Slow and costly over a whole list
  • A snapshot that changes as results move

Meaning first, results second

  • Embeds every phrase and compares them by cosine similarity
  • Runs on an embedding model, hosted or on your own machine
  • Shrinks several hundred phrases into candidate groups in seconds
  • Sends only the close calls to the results check
Fig 03 · Meaning first, results secondShared results are closer to the truth about intent and slower to get, so a good pipeline groups by meaning first and checks real results only for the close calls.

The difference is in what each one is actually measuring. Shared results measure how the search engine has already interpreted the intent behind each phrase, because the engine only ranks the same pages for two searches when it believes they want the same answer. Shared meaning measures how close the words are in a model's representation of language, which is a strong signal about topic and a weaker one about what the searcher wants to do. A phrase about a price and a phrase about booking can sit side by side in meaning and still want two different pages.

QuestionShared results (SERP overlap)Shared meaning (embeddings)
What it comparesThe top results each phrase returnsA vector for each phrase, compared by cosine similarity
What it needsSearch results from a licensed data source or a person checking by handAn embedding model, hosted or run on your own machine
What it catchesDifferent wordings that want the same pageSynonyms, reorderings and long-tail variants at scale
What it missesNothing about meaning; it is a snapshot that changes as results movePhrases that read alike but want different things
Where it belongsConfirming the close calls and the high-value groupsThe first pass over the whole list

So the order we use is meaning first and results second. Embeddings shrink a list of several hundred phrases into a few dozen candidate groups in seconds. Then only the groups that are close to a boundary, or that would justify a new page, get checked against real results. That keeps the slow, costly step small, and it keeps the cheap step from making the decisions it is worst at.

SERP overlap clustering: when two searches want one page

SERP overlap clustering puts two phrases in the same group when their top results share enough of the same URLs, on the reasoning that the search engine has already decided they want the same answer. If most of the pages ranking for one phrase also rank for the other, a single page can serve both, and building two would only make your own pages compete. If the two result lists share almost nothing, the searches want different pages, however similar the words look. There is no official threshold for how many shared results count as enough; SEO tools each pick their own, and Google publishes none.

When two searches want one page

Most URLs shared · words alike

One page

A single page can serve both searches

Most URLs shared · words differ

One page

The engine has already decided they want the same answer

Almost nothing shared · words alike

Separate pages

However similar the words look, the searches want different pages

Almost nothing shared · words differ

Separate pages

Two searches with two different answers

Left column: the two phrases' words look alike

Right column: the two phrases' words look different

Fig 04 · The results decide, not the wordsWhen the top results for two phrases share almost nothing, the searches want different pages however similar the words look; when they share most of their URLs, one page can serve both.

The catch is getting the results. Google's spam policies describe machine-generated traffic as sending automated queries to Google, and they name scraping results for rank-checking as an example, which they say violates both the spam policies and Google's Terms of Service. So a script that fires your keyword list at Google Search and reads the pages back is the one shortcut this step cannot take. Google's own programmatic route is closing too: the Custom Search JSON API overview says the API is closed to new customers and that existing customers have until 1 January 2027 to move to an alternative.

That leaves two legitimate sources of result data. One is a commercial search data provider that sells result data through an API, which a workflow can call for a short list of phrases. The other is a person, opening a private browser window and comparing the first page of results for two phrases side by side, which takes a couple of minutes per pair and is perfectly adequate for the dozen close calls that actually need it. Either way, the results are a snapshot: rankings move, so an overlap measured in spring is evidence about spring.

Semantic keyword clustering, and where meaning misleads

Semantic keyword clustering turns every phrase into an embedding, a list of numbers that places it in a space where phrases with similar meaning sit close together, and then groups the phrases that sit near each other. OpenAI's guide to vector embeddings lists clustering, where text strings are grouped by similarity, among the common uses and recommends cosine similarity as the measure. The work that made this fast for short texts is older than most SEO tools: the Sentence-BERT paper by Reimers and Gurevych reported cutting the search for the most similar pair in a collection from 65 hours with BERT to about 5 seconds. The full Python version of this step, from cleaning the export to setting a distance threshold, is in our guide to building a semantic keyword clustering system with Python.

Where semantic keyword clustering holds and where meaning misleads

  • Synonyms and reorderings Different wordings of one question sit close together in meaning
  • Long-tail variants at scale A list of a few hundred phrases is grouped in seconds
  • A question and a comparison about one tool They sit very close in meaning and usually want separate treatment
  • A price phrase and a booking phrase They share most of their words and want two different pages
  • A brand name that is also an ordinary verb It pulls unrelated phrases together
Fig 05 · The score is a proposalThe similarity score is a proposal, not a decision: semantic keyword clustering is reliable on synonyms and variants and misleads in predictable places, which go to the results check or to a person.

You do not need a paid service to try it. The open all-MiniLM-L6-v2 model on Hugging Face maps sentences to a 384-dimensional vector space, its model card names clustering and semantic search as uses, and it carries an Apache 2.0 licence, so a list of a few hundred phrases can be embedded on a laptop with no data leaving the building. If your stack runs on Claude, note that Anthropic's embeddings documentation says plainly that Anthropic does not offer its own embedding model and points to a third-party provider, so the embedding step uses a different service from the one that writes.

Meaning misleads in predictable places. A phrase asking what something costs and a phrase asking how to book it share most of their words and want two different pages. A brand name that is also an ordinary verb pulls unrelated phrases together. A question and a comparison about the same tool sit very close in meaning and usually want separate treatment. None of this makes embeddings useless; it means the similarity score is a proposal, and the groups near the boundary are exactly the ones that go to the results check or to a person.

From groups to a cluster map: the pillar and the spokes

A cluster map is the groups written down as decisions: one row per page you intend to have, with the phrase it is built for, the other phrasings it absorbs, the intent it serves, the page on your site that already covers it if one does, and what happens next. The pillar is the row for the broadest question your business can answer completely, and every spoke is a narrower question a reader of the pillar would ask next. It is a spreadsheet, not a diagram, because the next steps in the pipeline read it.

The pillar and the spokes in a cluster map

  1. PillarThe broadest question your business can answer completely
  2. SpokesNarrower questions a reader of the pillar would ask next
  3. LinksEach spoke points up to its pillar and across to its siblings
  4. PhrasingsThe other wordings each page absorbs
Fig 06 · The pillar is what you knowThe pillar is the broadest question your business can answer completely, chosen from what it knows rather than by search volume, and every spoke and link in the cluster map serves it.

Choosing the pillar by search volume is the commonest wrong turn. Volume estimates are useful, but Google's Keyword Planner help page describes the tool as research for Search campaigns and its numbers as estimates, which makes them a guide to demand rather than a measure of which subject you can speak to with authority. The better test is the one in our guide to identifying your knowledge pillars: the pillar is a subject your business genuinely knows, and the cluster is the shape that knowledge takes when it is published.

Each row should also carry its links before it carries any words. The spoke names the pillar it points up to and one or two siblings it points across to, so the internal links are planned, not sprinkled in after drafting. Google's guidance on making links crawlable asks for anchor text that is descriptive, reasonably concise and relevant to both pages, and it says every page you care about should have a link from at least one other page on your site. Automating internal linking in a content system covers how those planned links get written and checked once the pages exist.

Checking every group against the pages you already have

Before any group becomes a new page, the pipeline checks whether one of your existing pages already answers it, because the most common way a cluster goes wrong is a new page competing with an old one for the same search. Search Console already knows which of your pages Google shows for each query. The Search Analytics query method can return rows by query and by page, up to 25,000 rows per request, and its documentation is careful to say it returns the top rows rather than a guarantee of every row. Our explainer on Search Console’s API splitting branded searches adds a filter worth using at this check: matching only non-branded queries keeps your own name from looking like a topic you rank for.

Checking every group against the pages you already have

No page earns the query

Compare Datasets Only in the map: no page receives these queries

New page The group stays a proposed page in the cluster map

A page already earns it

Compare Datasets The same in both: a page earns these queries

Refresh Marked to refresh that page instead of a new URL

The checked cluster map, where no new page competes with an old one for the same search

Fig 07 · Refresh before you addChecking every group against your pages is mechanical, and it ends in one checked cluster map in which no new page competes with an existing page for the same search.

The comparison itself is mechanical. On one side sits the cluster map; on the other, the queries Search Console reports with the page that received each one. In n8n, the Compare Datasets node compares two input streams and sends each item to one of four outputs: only in the first, the same in both, different, and only in the second. A group whose phrases already earn impressions on one of your pages comes out on the matching branch and is marked for a refresh of that page instead of a new URL.

That rule is the same one the existence gate applies to a whole SEO pipeline, which our guide to automating SEO content without search spam sets out pattern by pattern. What changes here is the input: the gate reads groups that have already been checked against real data rather than a raw export. Refreshing the page that already ranks is usually the better trade, and how to automate content refreshes covers that half of the work. Keep in mind that the API's daily volume has its own limit too: Google's guide to getting your performance data says it exposes a maximum of 50,000 rows per day per search type, which a small site will never reach and a large one plans around.

A worked example: the search query that started this post

This post exists because of one row in our own Search Console. People were searching for SEO content cluster and SEO content automation, and the page Google showed them was our SEO content automation service page. So on 12 November 2026 we ran the check this post describes, on our own site, before writing a word. The tooling was not a product: it was two scripts that live in our website's repository, run from Claude Code in the way our guide to Claude Code for content automation describes.

The check we ran on our own site before writing this post

  • >Compare “SEO content cluster” with every published post before we write anything
  • ·Nearest posts: the SEO playbook for a Content OS, the content clusters guide, and automating SEO content without spam
  • ·SEO content automation is already the service page’s own keyword
  • >Count the posts that use the word cluster three times or more
  • ·Twelve other posts cross that line: five are about clusters in a real section, seven only mention one
  • ·Which of the seven belong on the topic page? Each needs someone who has read the post
  • +One written reason for every post that is not listed
  • Four decisions: a guide, the service page, a topic page and this post
Fig 08 · Our own query, checked firstBefore writing this post we ran two scripts from Claude Code against our own site, and the map made four decisions rather than one; the reason beside each unlisted post needed a person who had read it.

The first script compares a candidate search phrase with every published post's declared query, title, headings and FAQ, and prints the nearest existing posts with what each already covers. For SEO content cluster it returned three: the SEO playbook for a Content OS, our guide to content clusters, and our guide to automating SEO content without spam. Read side by side, those three already answered what a cluster is, how to choose one from what a business knows, and how a whole SEO pipeline stays clear of spam. The money phrase, SEO content automation, was already the service page's own keyword and was doing its job there.

So the map made four decisions rather than one. The definition stayed with the existing cluster guide. The service search stayed with the service page. The collection, SEO content clusters as a subject, got a topic page of its own that lists every article on it. And the one question none of our pages answered, how a keyword list actually gets grouped, became this post, with its own query. A model could have proposed all four rows; it took a person who knows what each of our pages is for to accept them.

The second script did the filing. It counted how often each of our posts uses the word cluster in its own prose and asked, for every post that uses it three times or more, whether the post belongs on the new topic page. Twelve of our other published posts crossed that line. Five are about clusters in a real section and were listed beside this one; seven only mention a cluster on the way to something else, and each of those got one written sentence saying why it is not listed. That sentence is the part a script cannot write, because it needs someone who has read the post. When we want the same check to run without us, Claude Code's documentation on running it programmatically shows the claude -p command with JSON output and a JSON Schema, which is how the result lands in a workflow as data rather than prose.

What the script groups, and what a person decides

The script does everything that can be counted and the person does everything that has to be answered for. Collecting the keywords, embedding them, grouping them, measuring overlap where results are available, matching groups to existing pages and writing the draft map are all repeatable steps with a clear right answer for most rows. Deciding which groups deserve a page at all, which page is the pillar, which close call goes which way, and whether a group fits what the business sells are judgements, and each one changes what the site will say in public.

What the script groups and what a person decides

The scriptA person

Collect

Collects and embeds the keywords

Decides what the business wants to be found for

Group

Groups the phrases and measures overlap where results exist

Merges the groups that are one question in two wordings

Close calls

Flags the groups near the boundary

Decides which close call goes which way

Existing pages

Matches groups to the pages you already have

Keeps a selling page’s phrases off the blog

The map

Writes the draft map

Approves each row and writes the reason beside it

Fig 09 · Small in hours, large in consequenceThe script does everything that can be counted and the person does everything that has to be answered for, and the close calls are where the two differ most.

Counted work for the machine and answerable work for a person is how every step of a content system splits, and our guide to what to automate in your content, and what not to applies that test beyond keywords. In a cluster map the person's work is small in hours and large in consequence: reading perhaps two dozen rows, rejecting the ones that would produce thin pages, merging the ones that are one question in two wordings, and writing a reason beside each decision. The reason column is what lets the next person, or the next run, understand why a row was refused.

Two kinds of group always go to a person, however confident the score looks. The first is any group that would put a buying search and a learning search on one page, because the page has to choose a reader. The second is any group whose phrases already belong to a page that sells something, because a blog post built for that phrase competes with the page that is meant to win it. SEO, AEO and GEO for automated content explains why the same page now has three kinds of reader, which is one more reason the choice of page is a person's.

What a cluster map takes to keep current

A cluster map is never finished, because the searches change, your pages change and the results change, so the honest cost is a small amount of attention on a schedule rather than one big project. For a business publishing a few articles a month, the first map is an afternoon of review once the script has done the grouping, and every later run is shorter because most rows carry a decision from last time. The time goes on the rows that moved: a new group, a group that now matches an existing page, or a close call that flipped. The technical chores each new page brings, its sitemap entry and its structured data, belong to website SEO automation and need no review once they are set up. Running that attention as scheduled checks on the website, with a short list of SEO decisions for a person, is what a Content Operating System for website SEO does.

The monthly run that keeps a cluster map current

01Pull

A scheduled workflow pulls the latest queries

02Re-embed

Any phrase it has not seen before is embedded

03Compare

The new groups are compared with last month’s map

04Review

A person reviews the rows that moved: a new group or a close call that flipped

The reviewed map becomes last month’s map for the next run, so every later run is shorter
Fig 10 · Never finished, always shorterA cluster map is never finished, but each monthly run only surfaces the rows that moved, because the reviewed map is what the next run compares against.

A monthly run is enough for most sites. In n8n, a scheduled workflow of the kind our guide to automating content with n8n builds pulls the latest queries, re-embeds any phrase it has not seen before, compares the new groups with last month's map and writes the differences to a sheet; the Google Sheets node has an append-or-update operation that adds a new row or updates the one that already exists, which is exactly what a map needs. The cost beyond time is the result data for close calls, if you buy it, and the embedding calls, which for a few hundred phrases are small. Once the cluster is live, how to measure a content system covers what to watch.

One change in search does not add to the work. Google's guidance on AI features says AI Overviews and AI Mode may use a query fan-out technique, issuing multiple related searches across subtopics, and also says there are no additional requirements or special optimisations needed to appear in them. Google's own announcement of AI Mode in May 2025 described the same technique as breaking a question into subtopics. A cluster that covers a subject's real sub-questions is already shaped for that, which is a reason to cluster well, not a reason to build a separate page for every sub-question a model might ask. If you would rather we built and ran this for you, website SEO automation pricing explains how that work is quoted.

Two other things move around a cluster map without changing how it is built. A core update can reshuffle which pages rank for a group's phrases, and our reading of the Google November 2026 core update covers how to read one in Search Console before you redraw anything. Whether your pages appear in AI Overviews at all is a separate setting, and our note on Search Console's generative AI control explains what it covers. And if the groups you approve need articles written for them, blog content automation pricing explains how that work is quoted.

Frequently asked questions

What is the difference between keyword clustering and a content cluster?

Keyword clustering is the analysis and a content cluster is the result. Keyword clustering sorts a list of search phrases into groups that one page could answer, while a content cluster is the set of published pages, a pillar and its spokes, built from the groups you decided were worth building. The cluster map sits between the two: it records which groups became pages, which merged, and which went to an existing page instead.

Is it allowed to scrape Google results to cluster keywords?

No, sending automated queries to Google and scraping the results breaks Google's spam policies, which name scraping results for rank-checking as an example of machine-generated traffic. Use a search data provider's API, or compare results by hand for the small number of close calls that need it. Embeddings, which need no search results at all, can do the first pass over the whole list.

Can a spreadsheet do keyword clustering without embeddings?

Yes, for a short list a spreadsheet and a careful person can cluster keywords well, by sorting phrases on their main words and comparing results by hand. It stops being practical somewhere in the hundreds of phrases, because every new phrase has to be compared with every group. Embeddings make the first pass fast at any size, and the spreadsheet remains the right place for the reviewed map.

How often should a cluster map be re-run?

Monthly suits most business sites, with an extra run after a large batch of new pages or a visible change in your Search Console queries. Each run should only surface what changed since the last map, so the review is short. Results drift, so any overlap measurement older than a few months should be treated as history rather than evidence.

Should every sub-question that AI Mode searches get its own page?

No, Google says AI Overviews and AI Mode need no special optimisation, and building a page for every sub-question produces exactly the thin, near-duplicate pages its spam policies warn about. A cluster that answers a subject's real questions on a sensible number of pages already gives a fan-out search something to find. Add a page when a sub-question has its own intent and a real answer, not because a model might ask it.

Which keyword groups should a person always check by hand?

A person should always check groups that mix a buying search with a learning search, groups whose phrases already belong to a service or product page, and groups whose similarity score sits near the boundary. Those are the cases where a confident score is most often wrong, and where a wrong call costs a page that competes with your own site. Everything else can usually be accepted from the draft map with a quick read.

Does keyword clustering help a small site with only a few dozen keywords?

It helps less as a technique and just as much as a habit. With a few dozen phrases you can group them by eye in an hour, and the real value is the cluster map that results: one row per page, its pillar, its links and the reason for each decision. That map is what stops a small site from publishing three posts that answer the same question.

Where to start

Export the last three months of queries and pages from your Search Console Performance report, and put them in a sheet beside the keyword list you already have. Group them by hand or with an embedding model, write one row per page you think should exist, and mark every row that an existing page already answers. Read that sheet with the question this post keeps returning to: which of these are genuinely new pages, and which are one page in several wordings? Google's help page on the Performance report explains what the position and click figures in that export mean. When the map looks right, the SEO content writing page shows how each row becomes an article worth publishing.

About the author

Shreyas Dave is the founder of Paper Eagle AI, and he still runs it. He designs Content Operating Systems for businesses with real expertise — the knowledge architecture, the content strategy and the automation that runs them, built in Claude Code and n8n, with Zapier or Make.com where they fit better. He writes from systems he has built and runs himself, including the ones behind Paper Eagle AI’s own publishing. Read more about Shreyas and how Paper Eagle AI started, or follow Shreyas Dave on LinkedIn, where he writes about content automation as he builds it.

Disclosure

This post was written by Shreyas Dave, founder of Paper Eagle AI. We sell content automation services, which is the category this article is about, so we have a commercial interest in you concluding that a system beats ad-hoc effort — read it knowing that. No tool vendor was involved in writing it, nobody paid for a mention, and there are no affiliate links anywhere on this site. Where a third-party figure appears, it’s attributed to the publisher it came from; anything we couldn’t source is written as a direction rather than a number.

Paper Eagle AI builds Content Operating Systems that turn a business’s knowledge and expertise into consistent, multi-platform content, and we deliver them as content automation services. Working as a content automation specialist, we capture what a business knows and how it sounds, set the strategy, and build the workflows that research, draft, repurpose and publish — with a named person approving every piece before it goes out. Every build runs through discovery, design, build and handoff. The system lives in the client’s own accounts, it is documented, the team is trained to run it, and the business owns it outright. We don’t write content on a retainer, and we don’t build lead generation, CRM or sales automation.

One source of thinking becomes native content for every platform a business publishes on: the founder’s LinkedIn and the company page, YouTube and Shorts, Instagram and Reels, TikTok, Reddit, Medium, newsletters, and the company’s own website, written to be found in Google and understood by AI search. Our multi-platform content automation page shows how they share one source, and our case studies document the systems behind our own publishing, file by file. You can follow the work on the company’s own channels: Paper Eagle AI on Instagram, Paper Eagle AI on YouTube, the Paper Eagle AI company page on LinkedIn, Paper Eagle AI on Substack, Paper Eagle AI on Reddit and Paper Eagle AI on Medium. Paper Eagle AI is also listed where clients can review its work: Paper Eagle AI on Clutch, Paper Eagle AI on GoodFirms and the Paper Eagle AI Google Business Profile.

Keep reading

A keyword list that never became a plan?

If you have exports, a tool subscription and a feeling that half your posts answer the same question, tell us what you publish. We will look at your Search Console queries and your pages with you and show you where the cluster map would draw the lines.

Start a Conversation