Search query clustering is grouping a list of keywords by meaning so that each group (cluster) can be covered by a single page of your site. It's the most important step between "I dumped a pile of keys into Wordstat" and "I understand which pages I need and what to write on them."
Without clustering you get a mess: thousands of queries, and no idea what to do with them. With it, you get a clear plan: 200 clusters → 200 pages with a concrete content brief.
| Method | Accuracy | Speed | Price |
|---|---|---|---|
| By SERP top (Hard/Middle/Soft) | medium | low | ~$5 / 1k |
| AI (Claude/GPT semantic) | high | high | ~$1 / 1k |
| Embeddings + agglomeration | highest | high | ~$3 / 1k |
Why cluster
A simple example. Your keyword core has 10 queries:
- buy a mountain bike
- mountain bike price
- men's mountain bike
- cheap mountain bike
- how to choose a mountain bike
- which mountain bike to choose
- mountain bike review
- mountain bike repair
- bike repair cost
- where to fix a bike
Question: how many pages does the site need? Not 10, of course. Queries 1-4 are one topic (buy a men's mountain bike), queries 5-7 another (how to choose), 8-10 a third (repair). That's 3 pages for 10 queries.
That's what clustering is. When you have 1,000+ queries, doing this by hand is impossible — you need an algorithm.
Why exactly one page per cluster
Search engines rank a page poorly across different intents at once. If on a single page you try to optimize for both "buy a bike" and "how to choose a bike," you usually lose both queries. Google and Yandex don't understand who to show your page to: the buyer or the reader.
When each cluster has its own page:
- The page has a clear intent (product / guide / FAQ / category).
- The title and H1 exactly match the cluster's main query.
- The text naturally covers all the variants within the cluster.
- Internal linking between clusters builds up logically.
This is the baseline SEO pattern of 2026.
Three clustering methods
1. By SERP top (Hard / Middle / Soft)
The most classic method, devised back in the 2010s. The idea: if two queries have the same pages standing in the search engine's top 10, then the search engine perceives these queries as one topic — so cluster them together.
The algorithm:
- For each query, collect the top 10 (say, Yandex's).
- Compare URL overlaps between queries.
- If there's enough overlap, merge into a cluster.
This is where the Soft / Middle / Hard modes appear, marking the match threshold:
| Mode | Minimum shared URLs in the top 10 | Result |
|---|---|---|
| Soft | 3 URLs | Large, loose clusters. May mix topics. |
| Middle | 4-5 URLs | A balanced option (used most often). |
| Hard | 7-8 URLs | Small, very close clusters. Many single queries. |
Pros of the method:
- Relies on the "opinion" of the search engine itself — meaning it's guaranteed to rank the way Yandex/Google sees it.
- Simple and predictable.
Cons:
- Requires a lot of SERP scrapes — that's expensive (you need Yandex.XML limits or Serper.dev / DataForSEO for Google). For 1,000 queries, that's 1,000 API calls.
- Doesn't account for intent if the SERP hasn't "settled" yet (for new niches).
- When the results change (and Yandex does this often), clusters can drift apart.
- Doesn't work for never-searched combinations — if a query has no real SERP, there's nothing to cluster it against.
2. Semantic clustering (on embeddings)
The modern approach. Each query is turned into a vector representation (an embedding) via a
language model (for example, OpenAI's text-embedding-3-small). Then vectors that are close in
meaning are grouped by a clustering algorithm (HDBSCAN, k-means, UMAP+DBSCAN).
The algorithm:
- Each query → a vector of size 384-1536.
- Run a clustering algorithm in this vector space.
- Get clusters by "semantic closeness."
Pros:
- No SERP scrapes needed — works in any niche.
- Understands meaning, not just URL overlap.
buy a bikeandbicycle buy(in Latin script) land in one cluster even if their results differ. - You can do hierarchical clustering: a main "bikes" cluster → subclusters "mountain," "folding," "kids'."
- Fast and cheap.
Cons:
- May merge queries that should be on different pages (for example, an informational and a commercial one with similar words).
- Quality depends on the embedding model and clustering parameters — it needs tuning.
3. AI clustering (on an LLM)
The newest approach (2024+). The list of queries is handed to a large language model (Claude, GPT-4) with the instruction: "group them and name each cluster." The model uses its general knowledge of SEO and semantics to build meaningful groups.
Pros:
- Accounts for semantics, intent, and context.
- Immediately gives each cluster a name (which is handy — regular algorithms don't provide names, and you have to set them by hand afterward).
- Can explain why it grouped things that way.
- Requires neither a SERP nor embeddings.
Cons:
- Costs more than mass computation (an LLM call isn't free).
- On very large cores (10,000+) you have to work in "batches" and then merge.
- Quality depends on the model and the prompt.
Our free clusterizer uses exactly this AI approach via Claude Sonnet — it gives good, meaningful clusters out of the box.
The hybrid approach
In real production services, two or three methods are often combined:
- Embedding clustering gives the initial split.
- The LLM checks and renames clusters.
- Optionally — a SERP check for the highest-volume queries.
How to cluster queries in 5 steps
Step 1. Prepare the list
You need a clean list of queries: no duplicates, no junk, one encoding, one per line. If you haven't cleaned it yet, clean it first, otherwise the clusterizer will work with noise.
The desirable amount is from 50 to 10,000 at a time. Under 20 — clustering gives a flat result. Over 10,000 — you need to split into batches.
Step 2. Choose a method
- Small list (up to 100), a single project — AI clustering (our free tool).
- Medium list (100-1,000), a typical niche — semantic + LLM check.
- Large list (1,000-10,000) with a budget — hybrid: embedding + SERP validation for commercial queries.
Step 3. Run it and get the result
Depending on the method, this takes from 30 seconds (LLM on 100 queries) to an hour (SERP method on 10,000). The output is a table:
| Query | Cluster | Intent |
|---|---|---|
| buy a mountain bike | Mountain bikes (buy) | commercial |
| mountain bike price | Mountain bikes (buy) | commercial |
| how to choose a mountain bike | Guide: choosing a mountain bike | informational |
Step 4. Review by hand
No algorithm gives 100% quality. A review is mandatory:
- Go through the clusters top to bottom.
- Too large (>50 queries) — see if it needs splitting.
- Too small (1-2 queries) — see if it needs merging with a similar one.
- The cluster name is clear — it'll become the page's H1.
On a large core, edits will be 5-15% — that's normal.
Step 5. Map to pages
Each cluster goes either to an existing page or to a new one. Out of this you get:
- A plan for creating new pages (prioritized by the cluster's frequency).
- A brief for the copywriter (main query → title, the rest → subheadings and body).
- A list of redirects (if two existing pages compete for one cluster — delete one and redirect it).
Common mistakes
- Clustering without cleaning. The algorithm works with what it's given. Junk in → junk clusters out.
- Setting Hard mode "for quality." In reality this gives hundreds of single-query clusters, and it's unclear what to do with them. Middle is usually more sensible.
- Ignoring intent. A cluster with "buy a bike" + "how to choose a bike" together is a typical mistake that breaks the CTR of both pages.
- Doing clustering once and for all. When you add new queries or the results change, the structure can "drift" — re-evaluate every 3-6 months.
- Ignoring low-frequency clusters. A query with 10 searches/month seems useless, but dozens of such clusters together give thousands of visits — the long tail.
How we can help
Semantic Core is a cloud service where clustering is built into the overall process: you upload or collect a core, we automatically clean it, cluster it (AI + a SERP check for commercial queries), and for each cluster you can generate a copywriter brief with one click.
To try clustering without signing up — the free AI clusterizer handles 5-100 queries at a time.