Google Search Console: use RegEx to find location based keywords

Like burgers and fries or pasta and parmesan cheese, Regular Expressions and Google Search Console is a match made in heaven.

With Regular Expressions (RegEx), you can filter the performance data of your website in Google Search Console (GSC) like never before. There are MANY ways to use RegEx filtering in Google Search Console. This tutorial’s intention is not to detail the different RegEx filter options. However, if you’re interested in learning more about the topic, I would encourage you to read the articles by Steve Toth and JC Chouinard.

This tutorial will see how to find location-based keywords for your website that Google already likes. This technique has two benefits. First, you can find opportunities to target local keywords with some low hanging fruit. The second possibility is to use this technique when reporting on SEO for clients or within your company. These are both useful for your SEO toolbox.

List your location keywords

Our first step is to compile a list of locations.

I’ll use a fictional company I created called Plumbers of London for this article since I can’t use my client’s Google Search Console data.

Let’s say that Plumbers of London offers plumbing services in Central London. I would, therefore, want to filter my GSC data using the following locations: Old Street, Clerkenwell, Covent Garden, Barbican, Farringdon, Moorgate, Whitechapel, Temple, Soho and Shoreditch.

Update the Google Sheets formula

The RegEx formula we’ll be using to find location-based keywords is simple:

.*(Location1 | Location2 | Location3 | Location4).*

Add your locations to the formula. Ensure to add the pipe character between the locations except for the first and last in your list. The pipe character stands for OR in RegEx.

The .* characters are a basic RegEx syntax that matches against any sequence of characters before and after your location keywords.

Using our Plumbers of London example from before, I set up a formula that looks like this:

.*(Old Street | Clerkenwell | Covent Garden | Barbican | Farringdon | Moorgate | Whitechapel | Temple | Soho | Shoreditch).*

Keep in mind that Google Search Console imposes a character limit of 4096 characters

Open Google Search Console

Open Google Search Console and navigate to the ‘Performance’ menu item.

GSC performance section

Select your analysis date range

You can select your preferred date range for analysis by clicking the ‘Date’ filter button. I chose the ‘Last 16 months’ for our fictional Plumbers of London example.


Tip: you can also use the ‘Compare’ date selection if you wish to compare month-to-month, year-to-year, or any other time frame.

Add your RegEx code

Click the ‘+ New’ filter button and select ‘Query…’ from the dropdown box.


Next, click the ‘Queries containing’ dropdown box and select the ‘Custom (regex)’ option.

Paste your copied formula that you created earlier into the ‘Enter regular expression (regex)’ box and click ‘Apply’.

The world is your oyster

That’s it. You’re done. Now you can marvel at the astounding number of keyword targeting opportunities you have discovered. In next month’s marketing report, you can dazzle your boss or client with some quick wins or show off some eye-opening marketing data.

You’re winning. And, it was that easy.

Tip: look for keywords that get a lot of impressions but very few clicks. These are typically keywords that are already getting a little love from Google. To find out what page ranks on Google for this particular keyword, click on the keyword and click on ‘Pages’. With a bit of optimization, you can score some quick wins.