historia.vg / Tools / Regex Tester

Regex Tester

This tool uses the built-in Javascript regex engine. Note that it may be different to Python/PCRE/etc.

Enter a pattern without surrounding slashes. For example: \b\w+\b

Thin purple markers indicate empty matches.

Enter a pattern to begin.

Matches

    CLI alternative

    Print matches with grep -E. Omit -o to print whole matching lines.

    grep -oE 'pattern' input.txt