Regex tester
Test a regular expression against text: matches, positions and captured groups.
How it works
JavaScript regular expression engine (same as browsers and Node.js).
Results are for guidance only and do not replace professional advice.
Worked example
With the default values:
- Pattern (without slashes)[\w.+-]+@([\w-]+\.)+\w{2,}
- Flags (g, i, m, s, u)gi
- Test textContact: hello@hod-group.com or support@example.co.uk
you get:
- Pattern/[\w.+-]+@([\w-]+\.)+\w{2,}/gi
- TipAdd g for all matches, i to ignore case
Frequently asked questions
How does the “Regex tester” tool work?
JavaScript regular expression engine (same as browsers and Node.js).
What do I need to enter?
Just fill in: pattern, flags, test text. The result updates as you type.
Can you give an example?
Pattern (without slashes): [\w.+-]+@([\w-]+\.)+\w{2,}; Flags (g, i, m, s, u): gi; Test text: Contact: hello@hod-group.com or support@example.co.uk → Pattern: /[\w.+-]+@([\w-]+\.)+\w{2,}/gi; Tip: Add g for all matches, i to ignore case.
Is this calculator free, and is my data private?
Yes. HOD Calc is completely free with no sign-up. The calculation runs in your browser: nothing you type is sent or stored.