Skip to main contentSkip to footer

Google Search Console Regex: 98 Copy-Paste Patterns for Queries and URLs

Google Search Console regex, ready to paste

98 copy-ready RE2 patterns for filtering queries and pages in Search Console, each with what it finds and an example. Use them to separate brand from non-brand traffic, group keywords by intent, and audit URL structure.

Try a pattern before you paste it

This tester runs in your browser, which is slightly more permissive than Google’s RE2. If a pattern uses lookaheads, lookbehinds or backreferences, the tester warns you because Search Console rejects them.

How to use a regex filter in Search Console

Copy button on a regex pattern in the whatisdigitalmarketing.in cheat sheet
Copy a pattern from this pageFind the pattern you need below and click Copy. The red box shows the button.
Google Search Console Performance report with the Add filter button highlighted
Open Performance and click Add filterIn Search Console, open Performance, then click Add filter above the chart.
Google Search Console Add filter menu with Query highlighted
Choose Query or PagePick Query to filter search terms. Pick Page to filter URLs.
Google Search Console Query filter dropdown with Custom (regex) highlighted
Select Custom (regex), then paste and applyChange Queries containing to Custom (regex). Choose Matches regex to include or Doesn’t match regex to exclude, paste your pattern and click Apply.
Google Search Console Top queries list filtered by a regex pattern
Review the filtered resultsTop queries now shows only the searches your pattern matches. Adjust the pattern and apply again to refine.

Search intent

Question queries

Finds queries that start with a question word. Good for FAQ sections, featured snippets and People Also Ask ideas.

Example: what is seo, how does ppc work

Matches regex(?i)^(who|what|when|where|why|how|which|can|could|does|do|did|is|are|was|will|would|should)\b

How-to queries

Isolates tutorial-style searches so you can see which step-by-step posts earn impressions.

Example: how to run google ads

Matches regex(?i)^how (to|do|can|does)\b

Definition queries

Finds top-of-funnel definition searches, the core of a topic-explainer blog.

Example: what is affiliate marketing, seo meaning

Matches regex(?i)^(what is|what are|what does|define|meaning of)\b|\b(meaning|definition|definitions)$

Why and problem-solving

Finds troubleshooting searches. These readers have a problem now, so they convert well on helpful posts.

Example: why is my traffic dropping

Matches regex(?i)^why\b|\b(not working|error|issue|issues|problem|problems|fix|fixed|solution|failed|failing|dropped|drop)\b

Informational queries

Groups research-stage searches where the reader wants to learn, not buy.

Example: seo guide for beginners

Matches regex(?i)\b(guide|tutorial|learn|learning|explained|explain|example|examples|tips|ideas|steps|checklist|basics|course|training|strategy|strategies)\b

Commercial investigation

Finds searches from people comparing options before a decision. Useful for roundups and review posts.

Example: best seo tools, semrush review

Matches regex(?i)\b(best|top|review|reviews|rated|ranking|recommended|worth it|pros and cons)\b

Comparison queries

Finds head-to-head and alternative searches, a strong sign of high buying intent.

Example: ahrefs vs semrush

Matches regex(?i)\b(vs|versus|compare|comparison|alternative|alternatives|difference between|better than)\b

Transactional and buying intent

Finds searches where the person is ready to pay or hire.

Example: seo services price in india

Matches regex(?i)\b(buy|price|prices|pricing|cost|cheap|cheapest|affordable|discount|coupon|deal|offer|order|quote|hire|subscription|plans?)\b

Navigational and login

Finds searches for a specific destination. Often branded and rarely worth new content.

Example: semrush login

Matches regex(?i)\b(login|log in|sign in|signin|sign up|signup|download|app|official|website|contact|customer care|support)\b

Free and trial

Finds price-sensitive searches. Good for lead magnets, free tools and templates.

Example: free seo audit tool

Matches regex(?i)\b(free|no cost|trial|freebie|open source)\b

Beginner level

Finds new learners. Helpful for planning beginner-friendly content.

Example: seo for beginners

Matches regex(?i)\b(beginner|beginners|basic|basics|for dummies|introduction|intro|101|starter|from scratch)\b

Tools, templates and software

Finds searches for something usable. Shows demand for calculators, checkers and downloads.

Example: keyword generator

Matches regex(?i)\b(tool|tools|software|plugin|plugins|template|templates|generator|checker|calculator|extension)\b

Jobs and careers

Finds career-minded searches, useful for a digital marketing learning blog.

Example: digital marketing jobs for freshers

Matches regex(?i)\b(job|jobs|salary|salaries|career|careers|hiring|vacancy|internship|freshers?|resume|interview)\b

Freshness and news

Finds searches that want current information. Shows where refreshing a post pays off.

Example: google core update news

Matches regex(?i)\b(today|latest|new|news|update|updates|recent|this week|this month|this year|now)\b

AI and LLM queries

Finds anything related to AI search and AI tools, a fast-growing topic cluster.

Example: chatgpt prompts for seo

Matches regex(?i)\b(ai|chatgpt|gpt|gemini|claude|copilot|perplexity|llm|llms|artificial intelligence|prompt|prompts|generative|ai overview)\b

AI-style prompts

Finds queries phrased like instructions to an AI assistant, a sign of conversational search behavior.

Example: give me a list of seo tools

Matches regex(?i)^(write|generate|create|draft|summarize|summarise|explain|give me|list|suggest|show me|tell me|help me)\b

Personal and conversational

Finds queries written in first person, typical of voice and AI-style searching.

Example: should i learn seo

Matches regex(?i)\b(i|i'm|im|my|me|we|our|can i|should i|do i)\b

Local and language

Near me

Finds explicit local-intent searches.

Example: digital marketing course near me

Matches regex(?i)\b(near me|nearby|near by|around me|close to me|in my area|open now)\b

City or region modifier

Finds searches that name a city or country. Edit the list to your target locations.

Example: seo agency in bangalore

Matches regex(?i)\b(in|near|at)\s+(mumbai|delhi|new delhi|bengaluru|bangalore|hyderabad|chennai|kolkata|pune|ahmedabad|jaipur|india)\b

Hinglish and Hindi words in Latin script

Finds Hindi searches typed in English letters. Shows if a Hindi version of your posts is worth writing.

Example: digital marketing kya hai

Matches regex(?i)\b(kya hai|kya|kaise|kaise kare|kyu|kyun|hindi me|hindi mein|ka matlab|batao|sikhe|seekhe)\b

Devanagari script

Finds queries typed in Hindi script. RE2 supports Unicode script names with \p{}.

Example: ?????? ?????????? ???? ??

Matches regex\p{Devanagari}

Any non-English characters

Finds queries containing any character outside plain English letters, including accents and other scripts.

Example: any non-ASCII text

Matches regex[^\x00-\x7F]

Query length

Single-word queries

Finds one-word head terms. Usually high volume, high competition.

Example: seo

Matches regex^\S+$

Two-word queries

Finds two-word queries. Often the main keyword of a page.

Example: seo audit

Matches regex^\S+\s\S+$

Three to four words

Finds mid-length queries, a sweet spot for many blogs.

Example: seo audit checklist free

Matches regex^(\S+\s+){2,3}\S+$

Five to six words

Finds the lower end of long-tail queries.

Example: how to do seo for beginners

Matches regex^(\S+\s+){4,5}\S+$

Seven or more words

Finds long, conversational queries. Great for AI and voice search insight.

Example: how to do keyword research for a new blog in 2026

Matches regex^(\S+\s+){6,}\S+$

Ten or more words

Finds very long, prompt-like queries. Often a sign of AI-assisted search.

Example: what is the best way to learn seo if i have no coding background

Matches regex^(\S+\s+){9,}\S+$

Exactly N words

Change the number inside {} to match an exact word count. This one finds three-word queries.

Example: seo tools list

Matches regex^(\S+\s+){2}\S+$

Brand and non-brand

Branded queries

Finds searches that name your site. Replace with your own brand spellings. Do not add the generic phrase 'what is digital marketing', because many non-brand searches contain it.

Example: whatisdigitalmarketing.in

Matches regex(?i)whatisdigitalmarketing|whatisdm|what is digital marketing\.in

Non-branded queries

Same pattern with Doesn't match. Shows only discovery traffic from people who did not search for you by name.

Example: everything else

Doesn't match regex(?i)whatisdigitalmarketing|whatisdm|what is digital marketing\.in

Brand plus modifier

Finds branded searches with a second intent word attached.

Example: whatisdigitalmarketing blog

Matches regex(?i)(whatisdigitalmarketing|whatisdm).*(login|contact|blog|course|review)

Brand misspellings

Catches spacing and spelling variants of your brand. Test it first, as it may overlap with generic searches.

Example: whatisdigitalmarket

Matches regex(?i)what\s?is\s?digital\s?marketing\s?(blog|in)|whatisdigitalmarket(ing)?

Characters and patterns

Queries with numbers

Finds any query containing a digit. Useful for list posts, versions and statistics.

Example: top 10 seo tools

Matches regex\d

Queries with a year

Finds searches that include a year from 2010 to 2029. Shows which evergreen posts need a year refresh.

Example: seo trends 2026

Matches regex\b20[12]\d\b

Queries with symbols

Finds queries containing punctuation or symbols, such as hyphens, quotes or plus signs.

Example: c++, e-commerce

Matches regex[^a-z0-9\s]

Starts with a word

Finds queries beginning with a specific word. Swap seo for your own term.

Example: seo audit

Matches regex^seo\b

Ends with a word

Finds queries ending with a specific word.

Example: technical seo

Matches regex\bseo$

Exact query only

Matches one query exactly, with nothing before or after.

Example: what is seo

Matches regex^what is seo$

Either of two words, nothing else

Matches queries that are exactly one of the listed words.

Example: seo

Matches regex^(seo|ppc)$

Exclude a list of words

Use Doesn't match to remove noisy intent groups and keep a cleaner view.

Example: hides those queries

Doesn't match regex(?i)\b(free|cheap|jobs|salary)\b

Contains two words in any order

Replaces a lookahead, which RE2 does not support, by checking both orders.

Example: audit for seo, seo site audit

Matches regex(?i)(seo.*audit|audit.*seo)

Contains a topic cluster

Groups a whole topic into one filter. Build one per cluster to compare topics.

Example: backlink checker

Matches regex(?i)\b(seo|search engine optimi[sz]ation|on.?page|off.?page|backlinks?|keywords?)\b

Spelling variants (UK and US)

Handles s or z spellings in one pattern using a character class.

Example: seo optimisation

Matches regex(?i)optimi[sz]ation|analy[sz]e|personali[sz]ation

Site structure

Homepage only

Matches the exact homepage URL. Update the domain if you use www.

Example: https://whatisdigitalmarketing.in/

Matches regex^https://whatisdigitalmarketing\.in/$

Everything inside a folder

Matches all URLs under one subfolder. Swap blog for any folder name.

Example: /blog/what-is-seo/

Matches regex^https://whatisdigitalmarketing\.in/blog/

Multiple folders

Matches several subfolders at once.

Example: /guides/ppc/

Matches regex^https://whatisdigitalmarketing\.in/(blog|guides|tools)/

Category archives

Finds WordPress category pages.

Example: /category/seo/

Matches regex/category/

Tag archives

Finds WordPress tag pages, which are often thin content.

Example: /tag/google/

Matches regex/tag/

Author archives

Finds author pages.

Example: /author/admin/

Matches regex/author/

Pagination pages

Finds paginated archive pages such as page 2 and page 3.

Example: /blog/page/2/

Matches regex/page/\d+/?$

Specific pages only

Matches an exact list of URLs. Add or remove slugs as needed.

Example: /seo/

Matches regex^https://whatisdigitalmarketing\.in/(seo|ppc|smm)/?$

Pages one level deep

Finds URLs directly under the domain, such as /about/ or /post-name/.

Example: /about/

Matches regex^https://whatisdigitalmarketing\.in/[^/]+/?$

Deep URLs (three or more levels)

Finds URLs buried three or more folders deep. Helpful for site architecture checks.

Example: /a/b/c/page/

Matches regex^https://[^/]+(/[^/]+){3,}

Subdomains

Finds any subdomain of your site, including www. Combine with Doesn't match on www to isolate others.

Example: https://blog.whatisdigitalmarketing.in

Matches regex^https://[a-z0-9-]+\.whatisdigitalmarketing\.in

Language folders

Finds language-specific folders. Edit the codes to match yours.

Example: /hi/seo/

Matches regex/(hi|en|ta|te|mr|bn)/

URL hygiene

URLs ending with a slash

Finds URLs with a trailing slash. Pair with the next pattern to spot inconsistent URLs.

Example: /blog/

Matches regex/$

URLs without a trailing slash

Finds URLs missing the slash. Mixed versions can split signals.

Example: /blog

Doesn't match regex/$

URLs with parameters

Finds any URL with a query string. Often duplicates or tracking links.

Example: /post/?ref=x

Matches regex\?

UTM tracking parameters

Finds URLs carrying campaign tracking tags.

Example: ?utm_source=news

Matches regex[?&]utm_

Uppercase letters in the URL

Finds URLs with capital letters, which can create duplicate versions.

Example: /Blog/SEO/

Matches regex[A-Z]

Underscores in the URL

Finds underscores. Hyphens are the usual separator for words.

Example: /seo_tips/

Matches regex_

Double slashes inside the path

Finds malformed URLs with a doubled slash after the protocol.

Example: site.in//blog/

Matches regex[^:]//

Long URLs

Finds URLs of 100 characters or more. Change the number to set your limit.

Example: very-long-slug…

Matches regex^.{100,}$

Insecure http URLs

Finds pages indexed on http instead of https.

Example: http://site.in/

Matches regex^http://

www versus non-www

Finds www versions of your pages. Use Doesn't match to see the non-www ones.

Example: https://www.site.in/

Matches regex^https://www\.

URLs with a hash fragment

Finds URLs containing a fragment, which usually should not be indexed.

Example: /post/#comments

Matches regex#

Stop words in the slug

Finds slugs padded with filler words. Shorter slugs are tidier.

Example: /what-is-the-best-seo/

Matches regex-(the|and|of|a|an|for|to|in|is)-

Dates in the URL

Finds date-based permalinks, such as /2025/08/post-name/.

Example: /2025/08/seo-tips/

Matches regex/20\d{2}/\d{2}/

Keyword in the URL

Finds URLs containing any listed keyword. Useful for topic-level reports.

Example: /seo-audit/

Matches regex(?i)seo|ppc|backlink

Files and WordPress extras

Media and document files

Finds files that appear in search, such as PDFs and images.

Example: /uploads/guide.pdf

Matches regex\.(pdf|jpg|jpeg|png|gif|webp|svg|docx?|xlsx?)$

WordPress system folders

Finds system paths that rarely belong in search.

Example: /wp-content/uploads/

Matches regex/wp-(content|admin|includes|json)/

Feed URLs

Finds RSS feed URLs.

Example: /blog/feed/

Matches regex/feed/?$

AMP pages

Finds AMP versions of pages.

Example: /post/amp/

Matches regex/amp/?$|[?&]amp

Internal search results

Finds WordPress search result pages, which are usually low value.

Example: /?s=seo

Matches regex[?&]s=

Comment reply URLs

Finds comment reply duplicates created by some themes.

Example: ?replytocom=12

Matches regex[?&]replytocom=

Exclude a folder

Use Doesn't match to hide archives and focus on real content pages.

Example: post URLs only

Doesn't match regex/(tag|category|author|page)/

RE2 cheat sheet

Start of text

Anchors the pattern to the beginning of the query or URL.

Example: ^seo

^

End of text

Anchors the pattern to the end.

Example: seo$

$

Any single character

Matches any one character. Escape it as \. for a literal dot.

Example: s.o

.

Zero or more

Repeats the previous item zero or more times.

Example: .* matches anything

*

One or more

Repeats the previous item at least once.

Example: \d+

+

Optional

Makes the previous item optional.

Example: colou?r

?

Either or

Matches a or b. Wrap in parentheses to limit the scope.

Example: (seo|ppc)

a|b

Group

Groups items together so you can repeat or alternate them.

Example: (on|off) page

(…)

Non-capturing group

A group that does not store a match. Slightly cleaner and faster.

Example: (?:on|off)

(?:…)

Character set

Matches any single listed character.

Example: optimi[sz]e

[abc]

Negated set

Matches any character not listed.

Example: [^/]+

[^abc]

Range

Matches a range of characters.

Example: [0-9]

[a-z]

Digit

Matches 0 to 9. \D is the opposite.

Example: \d{4}

\d

Word character

Letters, digits and underscore. \W is the opposite.

Example: \w+

\w

Whitespace

Space, tab or line break. \S is any non-space character.

Example: \S+\s\S+

\s

Word boundary

Edge of a word. Stops seo from matching inside seoul.

Example: \bseo\b

\b

Repeat exactly or between

Controls how many times an item repeats.

Example: \d{2,4}

{n} {n,m} {n,}

Case-insensitive flag

Put at the very start. Ignores uppercase and lowercase. Queries are lowercase, URLs may not be.

Example: (?i)^https://

(?i)

Escape a special character

A backslash makes the next symbol literal.

Example: \.com, \?, \/

\.

Unicode script

Matches characters from a named script such as Devanagari, Arabic or Han.

Example: \p{Arabic}

\p{Devanagari}

Not supported in GSC

Lookaheads, lookbehinds and backreferences do not work in RE2.

Example: use alternation instead

(?=…) (?<=…) \1
No pattern matches that search. Try a shorter word, or choose All.

Rules that save you time

  • Search Console regex is case-sensitive. Start the pattern with (?i) to ignore case. Queries are already lowercase, URLs often are not.
  • A pattern matches anywhere in the text unless you anchor it with ^ at the start or $ at the end.
  • Escape special characters with a backslash to match them literally, for example \.in or \?.
  • Page filters test the full URL, including https://. Anchor with ^https://yourdomain when you need precision.
  • Lookaheads, lookbehinds and backreferences do not work. Use alternation, such as (a.*b|b.*a), to check two words in any order.
  • Combine a regex filter with a date comparison to see how an intent group changes over time.
  • Keep each pattern under 4,096 characters, the Search Console limit.
Omkar Nath Nandi

Omkar Nath Nandi

17+ Years in Full Stack Marketing. AI Assisted Marketing Strategist. Built 200+ AI Assisted Marketing Tools. Specialist in Product Marketing, SaaS, B2B, B2C, SEO and Performance Marketing. Trained 100,000+ Professionals. IIT and IIM Guest Faculty | IIM Calcutta Alumni | Ex-Entrepreneur.

17 Years in Digital Marketing | 12 Years as Trainer

Creator • Builder • Analyzer • Marketer • Writer

Currently leading global digital marketing initiatives for a Gartner SIEM Magic Quadrant Leader. Over the past 17+ years, I have partnered with 500+ businesses to drive measurable growth through SEO, Performance Marketing, Product Marketing, SaaS Marketing, Demand Generation, and AI Assisted Marketing. I have built 200+ AI Assisted Marketing Tools and trained more than 100,000 professionals while helping organizations accelerate pipeline growth, strengthen brand visibility, and deliver measurable business outcomes.

1,00,000+
Students
4M+
Quora Views
1M+
Blog Views
Guest Faculty
IIT & IIM
$2M+ Managed Ad Budget
.
200+ Websites Built
200+ Vibe-Coded Apps

AI & Full Stack Tools Repositories

Digital Marketing & Utility Engine

Cybersecurity Threat AI Toolkit

Advanced AI-assisted toolset engineered for cyber threat analysis, infrastructure security mapping, vulnerability tracking, and real-time security operational metrics.

You might also like

More Similar Posts