正则表达式构建器

可视化构建和测试正则表达式

浏览器处理您的数据绝不离开浏览器

Quick Add Patterns

Regex Cheat Sheet

Characters

. Any character

\d Digit (0-9)

\w Word character

\s Whitespace

\b Word boundary

Quantifiers

* 0 or more

+ 1 or more

? 0 or 1

{'{'}n{'}'} Exactly n

{'{'}n,m{'}'} n to m

Anchors

^ Start of string

$ End of string

Groups

(abc) Capture group

(?:abc) Non-capture

a|b Or

About 正则表达式构建器

可视化构建和测试正则表达式

Use this free online 编程工具 tool to work faster without installing extra software. The interface is built for quick input, clear output, and straightforward results on desktop and mobile devices.

Processing

This tool runs in your browser whenever possible, which keeps your inputs private and reduces unnecessary round-trips to the server.