How To Use Regex Query in Google Search Console To Find Longtail Keywords and Questions

Sachin Seo
2 min readApr 21, 2021

--

Before we begin, here’s the regular expression for finding questions that begin with “who, what, where, when, why, how, was, did, do, is, are, aren’t, won’t, does, if.”

^(who|what|where|when|why|how)[” “]

For a more complete list of question-based modifiers, see the end of this post.

With this info you the find questions with high impressions and beef up your answers.

Today’s note is super simple and is based on a recent announcement by Google. As of last week (early April 2021) Google now recognizes regular expressions (regex) for querying search console.

This works for queries and pages. All you need to do is:

  • Open search console
  • Click “performance”
  • Click “new” and then “query”
  • select “Custom (regex)”
  • There is a bunch of stuff you can do with REGEX, but I’m just going to focus on one specific strategy I created.
  • We’re going to use the regular expression:

([^” “]*\s){7,}?

Type this into “query” “Custom (regex)” and it will show you all the keyword with 8 or more words in them.

If you want keywords with 10 words or more change the 7 to a 9.

If you want to find keywords with 4 words or more, change the 7 to 3.

If you change it to something like 20, you might find instances where people are cheating on tests. I found this in a few clients’ accounts.

So let’s go back to this:

([^” “]*\s){7,}?

Before you do anything, sort by impressions. Hopefully, you got some results (if you didn’t, try reducing the number of words).

What kind of results do we get with this?

LONGTAIL queries.

Let’s stretch it out even further:

([^” “]*\s){15,}?

My insight is this: use this regular expression to find high impression longtail queries where you don’t have the snippet, then add that exact query as an H2 (quick and dirty). Then use a technique like this to write a featured snippet.

who|what|where|when|why|how|was|did|do|is|

are|aren’t|won’t|does|if|can|could|should|would|

who|what|where|when|why|will|did|do|is|are|

won’t|were|weren’t|shouldn’t|couldn’t|cannot|can’t|didn’t|did not|does|doesn’t|wouldn’t

--

--

Sachin Seo

A hands-on Digital Marketing professional with more than two years of progressive experience at the forefront of SEO, Ecommerce and technical SEO