Skip to content
Tutorials Center
My learning

Topics

Lesson 12 of 36 ยท Keyword Research

Keyword Clustering and Mapping Keywords to Pages

Group related keywords into clusters, map each cluster to one page, avoid cannibalization and build a content plan. Includes runnable SERP-overlap clustering and mapping code.

A keyword list with 500 phrases is not a content plan. Many of those phrases mean almost the same thing and should be answered by one page, while others need separate pages. Keyword clustering groups phrases that belong together. Keyword mapping assigns each cluster to a single page on your site. Together they prevent two common problems: thin duplicate pages and pages that compete with each other.

Why clustering matters

Search engines understand meaning. A page about "how to repot a tomato plant" can also rank for "repotting tomatoes", "transplant tomato seedlings to bigger pots" and many more phrases, if it covers the topic well. Writing a separate page for each phrase splits your effort, produces near-duplicates and confuses engines about which page is the best answer.

On the other hand, merging phrases that need different pages (for example "tomato plants for sale" and "how to grow tomato plants") creates a page that serves neither intent.

How to decide what belongs together

Three tests, in order of reliability:

  1. SERP overlap. Search both phrases. If the results pages share many of the same URLs, the engine treats the phrases as the same need, so one page can target both.
  2. Intent match. Do both phrases want the same type of page? Informational and transactional phrases usually do not.
  3. Topic fit. Would a reader be happy to find both answers on one page, without it becoming too long or unfocused?
flowchart TD
    A["Two keywords"] --> B{"Do the top results<br/>overlap a lot?"}
    B -->|Yes| C{"Same intent?"}
    B -->|No| S["Separate pages"]
    C -->|Yes| M["Same cluster: one page"]
    C -->|No| S

A quick way to decide whether two keywords should share a page.

Try it: cluster keywords by SERP overlap

Professional tools cluster by comparing the URLs in each phrase's results. The program below uses made-up results (ten placeholder URLs per phrase) and groups phrases when at least four URLs overlap. It uses a simple "union-find" style merge so that indirect matches join the same group. Because the data is invented, the exact result only demonstrates the method.

Python Cluster by shared URLs

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

Notice that "transplant tomato seedlings" shares only three URLs with the repotting phrases, so at a threshold of 4 it stays alone. Change THRESHOLD to 3 and it joins the group. Different thresholds give different results, so tools let you tune it, and you should always check the actual results before merging.

Keyword mapping

A keyword map assigns each cluster to one URL (existing or planned). For each page, write down:

  • Primary keyword: the main phrase for the title, main heading and URL.
  • Secondary keywords: close variants and sub-topics to cover in headings and text.
  • Intent and page type: guide, category, product, comparison, tool.
  • Status: exists, needs improvement, to be created.

Rules for a clean map:

  1. One primary keyword per page, one page per primary keyword.
  2. A parent-child structure. Broad topics map to hub or category pages, specific topics to detail pages that link up and down.
  3. Check what you already have. Map to existing pages first; create new pages only for gaps.
  4. Avoid cannibalization. When two of your pages target the same query, they compete and neither performs as well as one strong page could.

Try it: build and check a keyword map

The program below stores a map and detects two kinds of problems: a primary keyword assigned to more than one URL (cannibalization risk), and URLs with no primary keyword. It is a pattern you can extend with real exports.

Python Keyword map checker

Press Run (or Ctrl + Enter) to see the result here.

Program input ยท what you'd type while the program runs

Type the answers before you press Run, one per line. Each time the program reads a line (with input()), it gets the next line from this box.

The conflict between the guide and the blog post is a real-world pattern. The fix is to merge the weaker page into the stronger one, redirect it with a permanent redirect and update internal links, or give the second page a genuinely different focus.

Cannibalization: symptoms and fixes

Symptoms: two of your URLs alternate in the results for the same query; rankings for the query jump up and down; neither page ranks well. A search console report filtered by a query shows several of your pages.

Fixes:

  • Merge overlapping pages into one stronger page and redirect the others.
  • Differentiate the pages: pick different intents or specific sub-topics, and rewrite titles and headings.
  • Use internal links so that the preferred page receives anchor text for the main phrase.
  • Canonicalize in special cases where duplicates must exist (such as filtered product pages).

From map to content plan

Sort the map by opportunity (from the previous lesson), mark which pages exist, and create a calendar: new pages first for high-value gaps, then updates for pages that rank on page two. Link every new page into the hub for its topic.

Check your understanding

Quick check ยท 4 questions

of 4 answered You scored / 4 ยท perfect!

  1. 1. What is the most reliable way to decide whether two keywords belong on one page?

    Overlapping results show that the engine treats the phrases as the same need.
  2. 2. What is keyword cannibalization?

    When several pages target the same query, they split signals and each one performs worse.
  3. 3. What is a good fix for two pages with the same primary keyword?

    Merging with a permanent redirect consolidates signals into one strong page.
  4. 4. How many primary keywords should a page have?

    A single focus keeps the page clear; secondary phrases support it.

Summary

  • Clustering groups phrases that one page can answer; mapping assigns each cluster to a URL.
  • Decide by SERP overlap, then intent, then topic fit.
  • One primary keyword per page; check existing pages before creating new ones.
  • Fix cannibalization by merging, differentiating or linking deliberately.

Next: Competitor and TF-IDF Analysis