Regex Tester

Test and debug regular expressions online in real-time. Free regex tester with syntax highlighting and match highlighting. Supports JavaScript regex syntax.

No account required. See the guide below for processing details and limitations.

Loading…

How to use

  1. Enter a JavaScript regular expression without the enclosing slashes.
  2. Paste test text and add flags, such as g for all matches or i to ignore case.
  3. Review the highlighted matches and their offsets. To preview a replacement, enter replacement text.

Example

On ‘Order 17 and order 29’, the pattern [0-9]+ with g highlights 17 and 29. With no flags, it shows the first match only.

Method, privacy & limitations

JavaScript RegExp syntax applies. The m flag lets ^ and $ match line boundaries. Offsets are zero-based UTF-16 positions. Test text is processed in your browser.

Frequently asked questions

Which flags are supported?

g (global), i (case-insensitive), m (multiline).

Does it highlight matches?

Yes. Matches are highlighted directly in the text.

Related tools for your next task