Semantically optimize pages for keywords using N-grams and AI!


This tool will help you optimize a page’s text based on high-performing queries from Google Search Console.

It automates on-page optimizations by increasing the keyword frequency of the top queries driving clicks to your page.


Try it here:

Google Search Console Direct Authorization Version

Copy/Paste The Keywords Manually Version


How it works:

  1. Scrapes your existing published web page
  2. Connects to Google Search console and pulls the highest-performing queries in the last 90 days
  3. Counts and scores the n-grams usage of your page text
  4. Determines where and how to increase usage for unused and underoptimized queries
  5. Outputs optimized text with increased keyword frequency (marked in bold)

Use the output to see how and where to edit your page for improved keyword usage. Edits will be bolded so you can see where they were added.

Note: It’s not perfect. It gets confused with abbreviations and specific industry jargon. You may have to make minor edits to your live pages. Don’t blindly copy/paste the suggestions.


Why optimizing GSC queries works:

Unlike most on-page optimization tools that aim to match keyword usage of competing pages, this tool focuses solely on increasing keyword usage for terms you already rank for.

By optimizing for these queries, you’ll be able to increase your visibility for those terms, and help Google index and rank your page for more related queries.

This helps increase traffic and rankings for the page as a whole over time.


Here’s an example of a page before and after optimizing for high-performing queries:

By optimizing this page for high-performing GSC queries, I increased the traffic to this page by 52% compared to the previous period (1.63k clicks vs 2.48k clicks).

It also helped the page get clicks from 30% more related queries that previously did not drive any clicks (174 queries to 225).

Imagine stacking those gains up across many more pages. It adds up!


Example output from the Google Search Console Query Optimizer:

I tried this app for one of my pages, the topical map generator. Here’s what It gave me:

The app highlighted several keywords  I hadn’t used on the page and showed me exactly how to incorporate them while still reading naturally.

Now I can easily update my text with these recommendations.


It also provided the same recommendations for under-optimized keywords:



What’s the difference between a Query and a Keyword?

You might be confused by the similarity between queries and keywords. These terms may seem interchangeable, but there is a difference:

  • Queries are search terms that users enter on a search engine to find relevant pages.
  • Keywords are groups of words found on a page or document that closely relate to a search term.

Keywords are often intentionally designed to exactly or closely match the queries they target.

This is an optimization tactic done to increase a document’s relevance to specific searches.

Both keywords and queries are often 2-3 words long. Longer queries that are 5+ words long are sometimes called long-tail queries.


Non-GSC Authorized Version:

The original version of this app connects directly to Google Search Console as an added convenience. However, if you don’t have access or you aren’t able to authorize Google Search Console, use this text-based version instead. It works the same way, but you provide it with the keywords to optimize manually instead of pulling them from search console.


Authorizing Google Search Console:

Important: You can only pull Google Search Console data for properties your Google account has authorized access to.

This app needs authorized access to your Google Search Console account to work. Here’s how to do that:

Step 1: Enter The GSC Property Name

GSC Property Name

Every website in your Google Search Console account has a property name.

To find your property name, click the “Search Property” dropdown in Search Console.

How to find your GSC Property Name

You’ll then see a list of all property names your account has access to.

Enter one of these property names into the app’s GSC Site Property Name field and hit run. It must be spelled exactly the same.

In my example, I can enter as my main domain property. This would pull queries by page for all subdomains.

And I can also do as a site property. This would only pull data for that specific subdomain.

I don’t have any subdomains on this domain. However, differentiating can be helpful when working with larger sites with multiple subdomains.


Step 2: Authorize Google Search Console

Screenshot of authorizing Moonlit to my Google account

Before using this app, authorize Moonlit to connect with your Google account.

Moonlit is the platform on which the app is built.

When you first hit “Run”, you should see a popup asking you to authorize the app. Click Continue.


Join the AI SEO Academy:

This app uses some cool Python tricks to count and score n-grams based on cosine similarity to the target keywords.

If that sounds like your cup of tea, you might like to learn how to use AI to improve and automate your SEO efforts.

Join the AI SEO academy to access over 30 more custom AI SEO tools just like this one!

Recommended Posts