GSC's "contains" and "exact match" filters work fine until they don't. The moment you need to isolate question queries, strip out brand traffic, or segment pages by URL path, those basic filters fall apart. Regex solves this, and Google Search Console supports it natively. The problem: GSC runs on Google's RE2 engine, not the PCRE flavor most tutorials teach. So that pattern you grabbed from Stack Overflow? It returns zero results with no error message. Silent failure, zero feedback.

Every pattern in this cheat sheet was tested against GSC's RE2 engine and cross-referenced with Google's official regex documentation. If a pattern silently breaks in GSC, we flag it and explain why.

Below you'll find 15+ copy-paste regex patterns organized in one scannable reference table, a breakdown of RE2 gotchas that trip up even experienced SEOs, a troubleshooting checklist for when your filter returns nothing, and "filter, analyze, act" workflows that turn filtered data into decisions. If you already know the basics and just need the patterns, jump straight to the cheat-sheet table.

How to Enable Regex Filters in GSC

If you've never used regex in GSC, here's how to find it. It takes four clicks:

  1. Open Performance → Search results in Google Search Console.
  2. Click + New at the top of the report.
  3. Choose Query (or Page).
  4. Switch the filter type from "Exact" to Custom (regex).

You now have two options: Matches regex and Doesn't match regex. Both are useful — "Doesn't match" is how you exclude brand terms or filter out unwanted URL sections.

Two things to know upfront:

  • Regex filters only work on the Query and Page dimensions. You can't regex-filter by country, device, or date.
  • Most people miss the "Doesn't match regex" toggle. It's one of the most powerful filtering options in GSC because it lets you exclude patterns instead of hunting for them.

GSC Uses RE2 Syntax — Here's What That Means for You

This is where most GSC regex problems start. Google Search Console uses the RE2 regex engine, not PCRE (the flavor you'll find on most regex tutorials and Stack Overflow answers).

RE2 was designed for speed and safety. The tradeoff: it drops several features that SEOs commonly try to use.

What works in GSC (RE2):

Symbol Meaning
. Any single character
* Zero or more of the preceding
+ One or more of the preceding
? Zero or one of the preceding
| OR operator
() Grouping
[] Character class
{} Quantifier (e.g., {3,5})
^ Start of string
$ End of string
(?i) Case-insensitive flag

What does NOT work in GSC:

  • Lookaheads: (?=...) and (?!...)
  • Lookbehinds: (?<=...) and (?<!...)
  • Backreferences: \1, \2
  • Atomic groups: (?>...)
  • Possessive quantifiers: *+, ++

These silently fail. GSC won't show an error — you'll just get 0 results and wonder what went wrong. If you've copied a regex from Stack Overflow and it returns nothing, this is almost certainly why.

One more detail: GSC regex is case-sensitive by default. If you're filtering for brand terms or queries with mixed capitalization, prepend (?i) to your pattern. For example, (?i)seo heatmap matches "SEO Heatmap," "seo heatmap," and "Seo Heatmap."

Quick RE2 Syntax Reference

Here's a minimal cheat sheet for reading the patterns in this guide:

Symbol What It Does Example Matches
. Any character s.o "seo", "s1o", "s-o"
* 0 or more colou*r "color", "colour"
+ 1 or more go+gle "gogle", "google", "gooogle"
? Optional https? "http", "https"
| OR cat|dog "cat" or "dog"
() Group (web)site "website"
[] Any char in set [aeiou] any vowel
^ Start of string ^how starts with "how"
$ End of string tool$ ends with "tool"
\s Whitespace \s+ one or more spaces
\S Non-whitespace \S+ one or more non-space chars
{n,} n or more times \S+(\s+\S+){4,} 5+ word string

The Regex Cheat Sheet: 15+ Patterns for Google Search Console

This is the master reference table. Bookmark it, print it, keep it in a tab — every pattern is RE2-compatible and ready to paste into GSC.

# Use Case Regex Pattern What It Matches Applies To
Intent Filters
1 Question queries ^(what|how|why|when|where|who|which|can|does|is|are|should) Queries starting with question words Query
2 Informational intent ^(what|how|why|when|where|who|which|guide|tutorial|learn) Informational queries Query
3 Transactional intent (buy|price|cost|cheap|deal|discount|order|purchase|coupon) Queries with purchase intent Query
4 Commercial investigation (best|top|review|compare|vs|alternative) Comparison/evaluation queries Query
Brand Filters
5 Brand queries (include) (?i)(yourbrand|yourbr4nd|your brand) All brand variations Query
6 Non-brand queries (exclude) (?i)(yourbrand|yourbr4nd|your brand) Everything except brand terms (use "Doesn't match") Query
Keyword Filters
7 Exact keyword ^your exact keyword$ Only this exact query Query
8 Keywords containing a term (?i)seo heatmap Any query containing the term Query
9 Keywords starting with ^how to Queries starting with "how to " Query
10 Long-tail (5+ words) ^(\S+\s+){4,}\S+$ Queries with 5 or more words Query
11 Short-tail (1–2 words) ^\S+(\s+\S+)?$ Queries with 1 or 2 words Query
URL / Page Filters
12 Blog pages only /blog/ URLs containing /blog/ Page
13 Specific site section /(blog|docs|pricing)/ URLs in blog, docs, or pricing Page
14 Pages with a parameter \? URLs with query strings Page
15 Subdomain filter ^https://blog\. URLs on a specific subdomain Page
Advanced Filters
16 AI-style long queries (9+ words) ^(\S+\s+){8,}\S+$ Very long, conversational queries Query
17 Conversational queries (how do i|what is the best way to|can you explain) AI/voice-style query patterns Query
18 Exclude specific pages /(admin|staging|test)/ Internal/non-public pages (use "Doesn't match") Page

How to use this table: Copy the pattern from the "Regex Pattern" column. In GSC, choose "Query" or "Page" based on the "Applies To" column. For rows 6 and 18, select "Doesn't match regex" instead of "Matches regex."

Replace placeholder terms (like yourbrand) with your actual brand name and misspellings.

Pattern Walkthroughs: Filter → Analyze → Act

The cheat sheet gets you filtered data. These walkthroughs tell you what to do with it.

Find All Question Queries

Pattern: ^(what|how|why|when|where|who|which|can|does|is|are|should)

Note the trailing space after the closing parenthesis — it prevents matching words like "however" or "wholesale."

What to do with the results:

  1. Sort by Impressions (descending).
  2. Look for queries with high impressions but low CTR or positions outside the top 5.
  3. These are your lowest-hanging fruit. High impressions mean demand exists. Low position means your current content isn't satisfying the question well enough.

Questions with high impressions but position 5+ are your best candidates for content expansion. Either add a dedicated section answering that specific question or create a new page targeting it.

This filter is also how you find featured snippet opportunities. Google pulls featured snippets from pages that directly answer questions — so if you rank 2–8 for a question query, tightening your answer could jump you to position 0.

Separate Brand vs Non-Brand Traffic

Brand pattern: (?i)(yourbrand|yourbr4nd|your brand)

Replace yourbrand with your actual brand name. Include common misspellings, abbreviations, and name variations inside the parentheses, separated by |.

Non-brand: Use the same pattern but select "Doesn't match regex."

Why this matters: Brand traffic inflates your perceived SEO performance. If 40% of your clicks come from people already searching your name, your "organic growth" chart looks better than your content SEO actually is.

Separating brand from non-brand gives you:

  • Honest content performance. Non-brand traffic shows how well your pages attract people who don't know you yet.
  • Better trend analysis. A brand campaign can spike branded searches and make it look like your SEO improved. Filter it out to see the real signal.
  • Clearer reporting. If you report to stakeholders, showing non-brand growth is a stronger proof point than total organic traffic.

Filter by Search Intent

These three patterns segment your queries by intent type:

  • Informational: ^(what|how|why|when|where|who|which|guide|tutorial|learn)
  • Transactional: (buy|price|cost|cheap|deal|discount|order|purchase|coupon)
  • Commercial investigation: (best|top|review|compare|vs|alternative)

Run each one separately and compare the metrics.

What to look for:

  • High-impression informational queries with low CTR → Your title/meta description may not match the question. Rewrite to address the query directly.
  • Transactional queries going to informational pages → Create a dedicated landing page or add conversion elements to the content page.
  • Commercial investigation queries → These people are comparing. If they're landing on your blog instead of a comparison or pricing page, you're losing them.

Intent segmentation is one of the most underused regex workflows. It tells you whether your content strategy is attracting the right traffic — not just any traffic.

Find Long-Tail Keywords (by Word Count)

Pattern for 5+ words: ^(\S+\s+){4,}\S+$

Here's how the pattern works: \S+ matches a word (non-whitespace characters). \s+ matches the space between words. {4,} means "4 or more spaces," which equals 5 or more words. The ^ and $ anchors ensure the full query is evaluated.

Adjust the number for different thresholds:

  • 4+ words: {3,}
  • 7+ words: {6,}

Why this matters: Long-tail queries are typically higher-intent and lower-competition. A query like "best free seo tool for small business" tells you exactly what the searcher wants — and there are fewer pages competing for it than "seo tool."

Filter for long-tail, then sort by impressions. If you see long-tail queries where you rank 5–15 with decent impressions, those are pages where adding depth or creating a dedicated article could push you into the top positions.

Segment Pages by URL Section

Pattern: /(blog|docs|pricing)/

Swap the section names for whatever your URL structure uses — /resources/, /products/, /help/, etc.

This filter answers a simple but important question: which part of your site drives the most search visibility?

How to use this:

  1. Run the pattern for each site section separately.
  2. Compare total impressions, clicks, and average CTR across sections.
  3. If your blog gets 80% of impressions but 20% of clicks, your titles and meta descriptions need work — or the traffic is too top-of-funnel to convert.
  4. If product pages get high CTR but low impressions, you have a distribution problem, not a conversion problem.

You can combine a page regex with a query regex within GSC's 2-filter limit. For example: page matches /blog/ AND query matches ^(what|how|why) — to see only question-driven traffic hitting your blog.

Detect AI-Style Queries

Long queries (9+ words): ^(\S+\s+){8,}\S+$

Conversational markers: (how do i|what is the best way to|can you explain)

Search behavior is changing. With AI Overviews and conversational search tools, queries are getting longer and more natural-sounding. Monitoring these patterns in GSC tells you how much of your traffic is shifting toward conversational search.

What to do:

  • Track the volume of 9+ word queries month over month. If it's growing, your content strategy needs to account for full-sentence questions, not just 2–3 word keywords.
  • Look at which pages attract conversational queries. Are they your FAQ pages? Blog posts? Product pages? This tells you where Google thinks you answer questions well.
  • If you see conversational queries with high impressions but low clicks, consider restructuring those pages with direct, concise answers at the top. AI Overviews and featured snippets favor content that gets to the point.

When Regex Hits a Wall: GSC's 2-Filter Limit

Here's the frustration nobody talks about: Google Search Console only allows 2 filters at the same time.

That means you can combine query regex + page filter. Or query regex + country. But you can't do all three. You can't filter for question queries on /blog/ pages in Germany in the last 90 days. That's four dimensions — GSC caps you at two.

This hits hard when you're doing anything more than basic filtering:

  • Want to see non-brand question queries on your blog? That's query regex (non-brand) + query regex (questions) + page filter (/blog/) — three filters. Can't do it.
  • Want to compare intent segments across two site sections? You'd need query regex (intent) + page regex (section) — that works, but now you can't add a date range comparison without running separate reports.

The Workarounds (and Their Problems)

Workaround 1: Run multiple passes manually. Apply two filters, note the data, change the filters, repeat. This works for one-off analysis but doesn't scale.

Workaround 2: Export to spreadsheets. Pull the raw data and filter with REGEXMATCH() in Google Sheets or Python scripts. This removes the 2-filter cap but creates a new problem.

As one SEO put it: "You can't filter in Google Search Console by more than 2 keywords or landing pages. And pulling everything into spreadsheets takes a lot of time and it's tedious — you end up with a lot of similar spreadsheets that are easy to mix up."

Spreadsheet sprawl is real. Every analysis becomes its own file, and before long you're maintaining a graveyard of tabs you'll never open again.

Workaround 3: Use a visual layer on top of GSC. Tools like SEO Heatmap connect to your Search Console data and let you slice it any way you want — by query, page, intent, position, date range — without the 2-filter limit. Instead of spreadsheet exports, you get a visual interface built specifically for the kind of analysis regex users are already trying to do in GSC.

Why Your Regex Returns 0 Results (Troubleshooting)

GSC's biggest regex UX problem: when your pattern is invalid, it doesn't show an error. It just returns 0 results. This makes debugging painful because you can't tell whether your regex is wrong or the data simply doesn't exist.

Run through this diagnostic checklist:

1. Did you use a PCRE-only feature? Lookaheads ((?=...)), lookbehinds ((?<=...)), and backreferences (\1) don't work in RE2. This is the #1 silent failure. If your pattern came from Stack Overflow or a regex tutorial, it probably uses PCRE syntax.

2. Did you forget (?i) for case-insensitive matching? GSC regex is case-sensitive by default. The query "SEO Tools" won't match the pattern seo tools unless you prepend (?i).

3. Did you escape special characters? If you're filtering URLs, remember that . means "any character" in regex. The pattern example.com/blog also matches exampleXcom/blog. Use example\.com/blog to match only the literal dot.

4. Is your pattern too long? GSC has a character limit on regex patterns. If your pattern is complex with many alternatives, try simplifying it or splitting into separate filters.

5. Did you select the right toggle? "Matches regex" and "Doesn't match regex" do opposite things. Double-check you haven't accidentally inverted your filter.

6. Is there data for that filter + date range combination? If you're filtering for a very specific pattern over a short date range, there might genuinely be 0 matching queries. Widen the date range first to verify the pattern works at all.

Test Before You Paste

Use regex101.com to test your patterns — but change the regex flavor to Golang (RE2) before testing. The default flavor is PCRE, and patterns that work in PCRE may silently fail in RE2.

Steps: Open regex101.com → click the flavor selector on the left sidebar → choose "Golang" → paste your pattern. If it works there with the RE2 flavor, it'll work in GSC.


If regex in GSC feels limiting — because it is — SEO Heatmap lets you slice your Search Console data any way you want, without the 2-filter cap or spreadsheet exports. It visualizes your GSC data so you can spot patterns in seconds instead of wrestling with regex syntax and filter limits. Give it a try. It's free.

Frequently asked questions

What regex syntax does Google Search Console use?

Google Search Console uses the RE2 regex engine, which Google built for speed and safety. RE2 supports standard metacharacters like . * + ? | () [] {} ^ $ and the (?i) flag for case-insensitive matching. It does not support lookaheads, lookbehinds, backreferences, or possessive quantifiers. If a pattern works on regex101.com with the Golang/RE2 flavor selected, it will work in GSC.

What is the difference between "contains" and regex filters in GSC?

The "contains" filter checks whether a plain text string appears anywhere in the query or URL. Regex filters let you match patterns: word boundaries, alternation (OR logic), anchoring to the start or end of a string, and character classes. Use "contains" when you're looking for a single fixed phrase. Switch to regex when you need to match multiple terms at once, filter by word count, or anchor a match to a specific position in the string.

Can I use regex filters on all dimensions in Google Search Console?

No. Regex filters only work on the Query and Page dimensions. You cannot apply regex to country, device, search type, or date range filters. If you need to combine regex with those dimensions, apply the non-regex filter first (like selecting a country), then add your regex filter on Query or Page as one of your two allowed filters.

Is there a character limit for regex patterns in GSC?

Yes, though Google does not publish the exact limit. In practice, patterns longer than roughly 200 to 250 characters may get truncated or return unexpected results. If your pattern has many alternatives separated by |, try shortening brand name variations, removing redundant terms, or splitting the filter into two separate analyses.

Can I save or bookmark regex filters in Google Search Console?

GSC does not let you save regex filters for reuse. Every time you open the Performance report, you start with a clean slate. The workaround is to keep a reference document (spreadsheet or text file) with your commonly used patterns so you can copy and paste them quickly. Some third-party tools that connect to the Search Console API let you save and rerun filter presets.

Does regex work in the Google Search Console API?

Yes. The GSC API (Search Analytics method) supports regex through the CUSTOM_REGEX operator in dimension filters. It uses the same RE2 engine as the web interface, so patterns that work in the GSC UI will also work via the API. The API removes the 2-filter limit of the web interface, which makes it the better option for complex multi-dimension analyses.

Does GSC regex work in Discover and Google News reports?

Regex filters are available in the Discover and Google News performance reports, but only on the Page dimension. Since Discover and News reports do not have a Query dimension (Google does not expose the triggering query for Discover), you can only use regex to filter by URL patterns like /blog/ or /(news|updates)/.

Why does my regex pattern match on regex101.com but return nothing in GSC?

The most likely cause is a syntax mismatch. regex101.com defaults to the PCRE flavor, which supports features that RE2 (GSC's engine) does not. Switch the flavor selector to Golang before testing. If the pattern still works in Golang mode but fails in GSC, check that you included (?i) for case-insensitive matching, escaped literal dots in URLs with \., and selected the correct "Matches regex" or "Doesn't match regex" toggle.