Tool to analyze topical relevance for On-Page SEO

author avatar
Matthias Kupperschmidt
16. November 2020
2min read

One ingredient for high ranking pages in Google's search results is to cover a topic thoroughly - or at least better than your competitors.

But how can you ensure you do this?

A nifty way to determine the subtopics you should include in an article is looking at the subtopics of pages that are already ranking.

Following this approach, you save time researching subtopics and guessing which ones should go into your main article.

This is how it looks like for the keyword "best backlink tool":

Compare subtopics of competitors side by side.

With this method you can:

  • plan your content outline fast
  • make sure you cover the most important subtopics
  • find opportunities for topics others are not covering yet

This is all great - except it's a pain to manually extract headlines from the top Google results and put them in a sheet.

As an SEO freelancer, I try to automate as much as I can, since it is the only way for me to scale. That's why I automated the process and below I'm sharing the tool with you so you can do the analysis yourself in just seconds.

Competitor heading extractor tool to analyze topical relevance

The tool runs in Google Colab, so let me quickly show you how it works:

Here is the link to the script.

This is what you need to run it:

  • Google account
  • URL's of competing pages

Step-by-Step guide to run the Python script

  1. First, go to the tool in Google Colab and Save a copy in Drive.
    Save a copy of the Python tool in Google Colab.
  2. Execute the first code block by pressing the play button.
    Play first code block in Google Colab.
  3. Click the link in the output to get the authentication key, then paste it into the empty field and press enter. This allows Google Colab to create a Google sheet.
  4. Search for your target keyword on Google, then copy and paste the URLs of the search result pages into the form.
    Copy URLs of the Google search result pages into the input-form
  5. Give the Google Sheet a name.
    Add a name for the Google Sheet
  6. Execute the second code block by pressing the play button.
    Execute the next Python code block by pressing the play button.
  7. Execute the third code block by pressing the play button.
    Execute the last code block in Google Colab
  8. Done. Go to Google Sheets and open your newly created sheet holding all of your competitor's headlines.
    Compare subtopics of competitors side by side.

How many subtopics should you include in the content for SEO

Group the subtopics of your competing pages to find out what they most-commonly talk about. Add the most common topics to your content outline.

To exceed competing content, add 1-2 additional subtopics that you find important.

But how can you find additional relevant topics that nobody is talking about yet?

  • helps you find related questions to your keyword. Answer them the ones you deem most relevant to your visitor.
    Research topically relevant Questions on
  • Another method is to look at what Google deems highly relevant to your topic. StreamSuggest scrapes all auto-suggest keywords for you and enters each one again to scrape all of their keyword suggestions again. It shows you all related auto-suggestions in seconds:
    Related keyword suggestions from Streamsuggest.

Let's wrap up what we learned.


  • You can ensure topical relevance, by analyzing the subtopics of top-ranking Google result pages
  • My tool allows you to scan subtopics and create the content outline fast
  • To exceed competitors content, add 1-2 additional subtopics, e.g. answer a relevant question or explain another topic that Google finds relevant

That's it. Let me know on Twitter if you liked this and if it helped you to improve your SEO content. ✌️

author avatar
Matthias Kupperschmidt
16. November 2020
2min read