image Image
Convert Image Image to Base64 Converter
descriptionText
Compare textText to Hex Text to Base64 Word CounterCase ConverterVietnamese Accent Remover & Slug GeneratorRegex Tester
Json
Json to Excel/Csv JSON ⇄ YAML ConverterJSON to TypeScript, C# & Go
table_chartExcel
Excel/Csv to Json Excel/Csv to Sql Excel/Csv to Html
scheduleTime
Convert datetime Timezone Info
Url
Encode and Decode URLs Shorten URL
smart_displayVideo
Download Youtube
Sql
Statistics Parser Statistics Compare
SEO
Create Sitemap
listFormatter
Json FormatterXML FormatterCSS FormatterHtml FormatterJs FormatterSql FormatterException Formatter
listOther
Convert TokenConvert HashColor PickerGenerate PasswordQR Code GeneratorQR Code ScannerVietQR Bank Transfer QR GeneratorUUID / ULID / NanoID GeneratorNumber Base Converter
searchSearch
Search tools
codeTracer
C# Tracer Formatter
help_outlineAbout
About UsPrivacy PolicyTerms of Service
THUTOOL
other tool Case Converter keyboard_double_arrow_right Json to Excel/Csv keyboard_double_arrow_right Shorten URL keyboard_double_arrow_right

Regex Tester

🔒 Processed 100% in your browser – your data never leaves your device
//g
Flags:
Matches highlighted

How to use the Regex Tester

Enter a regular expression without the surrounding slashes, tick the flags you need, and paste your test text. Matches are highlighted as you type, and a table below lists every match with its position and capture groups. The tester uses your browser's JavaScript RegExp engine, so results are exactly what your JavaScript or TypeScript code will get. Your pattern and text never leave your browser.

Flags

g finds all matches instead of only the first. i ignores case. m makes ^ and $ match at every line. s lets . match line breaks. u enables full Unicode, including \p{L} property escapes. y (sticky) only matches at the position where the previous match ended.

Groups and replace

Numbered groups ( ) appear as $1, $2… and named groups (? ) appear with their name. Turn on Replace to preview the result of text.replace(). You can use $1, $, $& (whole match) and $$ (a literal dollar sign) in the replacement.

FAQ

Why do I see an error? The pattern has a syntax error, such as an unclosed bracket. The message from the browser tells you what is wrong.

Why are only 1000 matches shown? To keep the page fast, matching stops after 1000 results. Empty matches (for example from a*) are shown as a thin marker and never cause an endless loop.

Related tools

  • Compare textCompare two texts line by line and highlight every difference instantly. Free online diff tool that runs 100% in your browser.
  • Text to HexConvert text to hex, binary, ASCII and decimal, or decode hex and binary back to UTF-8 text. Free, instant and processed in your browser.
  • Text to Base64Encode text to Base64 or decode Base64 to text with full UTF-8 support, including URL-safe Base64. Free and processed in your browser.
  • Case ConverterFree case converter: UPPER, lower, Title, Sentence, camelCase, PascalCase, snake_case, kebab-case and more, all at once. Runs in your browser.
  • Vietnamese Accent Remover & Slug GeneratorFree tool to remove Vietnamese accents and generate SEO-friendly URL slugs, line by line in bulk. Choose - or _ and max length. Runs in your browser.
  • Word CounterFree online word counter: count words, characters, sentences, paragraphs and reading time live. Supports Vietnamese and CJK. Runs in your browser.
@Made by THUTOOL