FindPrompts
Sign InGet Started

Get the best new prompts every week

Join the FindPrompts newsletter — top prompts, fresh mastery guides, and AI workflow tips. Free, no spam.

FindPrompts

The largest AI prompts database. 30,000+ prompts for ChatGPT, Claude, Midjourney, and more.

Categories

  • Marketing
  • Business
  • Writing
  • Coding
  • Education

Platforms

  • ChatGPT
  • Claude
  • Gemini
  • Grok
  • Midjourney

Resources

  • Best AI Prompts
  • Free Tools
  • Prompt Grader
  • Prompt Templatizer
  • AI Token Counter
  • Image Prompt Generator
  • System Prompt Generator
  • Prompt A/B Tester
  • Prompt-to-JSON
  • Headline Generator
  • AI Cost Calculator
  • AI Prompt Improver
  • Prompt Generators
  • Mastery Guides
  • Cheatsheets
  • Automations
  • AI Tools
  • Custom GPTs
  • Blog
  • Affiliate Program

Company

  • Pricing
  • Contact
  • Terms of Service
  • Privacy Policy

© 2026 FindPrompts. All rights reserved.

TwitterGitHub
FindPrompts
FindPrompts

Main

Dashboard
Prompt Library30k+
DiscoverHot
LeaderboardNew
BundlesNew
Prompt Maker
PlaygroundBeta
GeneratorsNew
WorkflowsPro

Personal

Compare
Prompt Improver
Prompt Grader
Templatizer
Token Counter
Image Prompts
System Prompts
A/B Tester
All Free Tools
My Vault
Analytics
Submit Prompt
AI Tools
Guides
Cheatsheets
Automations
Settings
Go Pro

Unlock workflows, API access, and premium features.

Upgrade Now

User

Command Palette

Search for a command to run...

HomeCheatsheetsRegex Cheatsheet
Coding6 min

Regex Cheatsheet

The regex tokens and patterns developers ask AI for most. Covers character classes, anchors, quantifiers, and battle-tested patterns for email, URLs, and dates.

Character Classes

.Any character except newline.
\d / \DA digit / a non-digit.
\w / \WWord char [A-Za-z0-9_] / a non-word char.
\s / \SWhitespace / non-whitespace.
[abc]Any one of a, b, or c.
[^abc]Any char except a, b, or c.
[a-z]Any char in the range a to z.

Anchors & Boundaries

^Start of string (or line in multiline mode).
$End of string (or line in multiline mode).
\bWord boundary, e.g. \bcat\b matches whole word cat.
\BNon-word boundary.
\A / \ZAbsolute start / end of string (in flavors that support it).

Quantifiers

*Zero or more of the preceding token.
+One or more.
?Zero or one (optional).
{n}Exactly n times.
{n,}n or more times.
{n,m}Between n and m times.
*? / +?Lazy versions: match as few characters as possible.

Groups & Logic

(...)Capturing group; backreference with \1, \2, ...
(?:...)Non-capturing group.
(?<name>...)Named capturing group, referenced as \k<name>.
|Alternation: cat|dog matches either.
(?=...)Positive lookahead: followed by ...
(?!...)Negative lookahead: not followed by ...
(?<=...)Positive lookbehind: preceded by ...

Handy Patterns

Email (simple)^[\w.+-]+@[\w-]+\.[\w.-]+$
URLhttps?:\/\/[^\s/$.?#].[^\s]*
IPv4\b(?:\d{1,3}\.){3}\d{1,3}\b
Date YYYY-MM-DD\d{4}-\d{2}-\d{2}
Hex color#(?:[0-9a-fA-F]{3}){1,2}\b
Phone (loose)\+?\d[\d\s().-]{7,}\d
Whitespace trim^\s+|\s+$ (replace with empty string).

Related Cheatsheets

SQL Quick Reference Cheatsheet

Core SQL syntax for querying, joining, and shaping data.

Git Commands Cheatsheet

Everyday git commands for branching, committing, and fixing mistakes.

Want ready-to-use prompts to go with this cheatsheet?

Browse 30,000+ Prompts