Test regular expressions, extract emails, phone numbers, URLs,
dates and other text patterns. Highlight matches, find and replace
content, and download your extracted results.
1. Regular Expression Tester
2. Text Extractor
Paste your text below, select a ready-made pattern or enter your own
Regex pattern. The tool will extract matching content from your text.
0Total Matches
0Text Characters
0Pattern Characters
Highlighted Matches
Your highlighted matches will appear here.
Extracted ResultsNo results yet
No matches yet.
Tip: Choose Email, Phone, URL or another preset above
to quickly extract that type of information. You can also write your
own Regex pattern.
3. Find & Replace
4. Regex Code Examples
Use your current pattern and flags in your application.
JavaScript
PHP
Python
JavaScript, PHP and Python have some differences in Regex syntax.
A pattern supported in one language may need adjustments in another.
What Is a Regular Expression?
A regular expression, commonly called Regex or RegExp, is a sequence
of characters used to search, match, validate and replace text
according to a specific pattern.
Developers use regular expressions for email matching, extracting
phone numbers, checking formats, cleaning text, processing data
and searching through large amounts of content.
Common Regex Symbols
\d — Matches a digit from 0 to 9.
\w — Matches a word character.
\s — Matches whitespace.
. — Matches most individual characters.
+ — Matches one or more occurrences.
* — Matches zero or more occurrences.
? — Makes a quantifier optional or non-greedy.
^ — Matches the beginning of a string or line.
$ — Matches the end of a string or line.
[abc] — Matches any listed character.
\b — Matches a word boundary.
Common Text Extraction Examples
Email: Extract basic email address patterns from text.
Phone: Find phone-like number sequences.
URL: Find HTTP and HTTPS links.
Dates: Find dates written as YYYY-MM-DD.
Numbers: Extract integer and decimal numbers.
IPv4: Match common IPv4 address formats.
Why Use HoxTools Regex Tester?
Test regular expressions directly in your browser.
Highlight matching text visually.
Extract all matching results.
Download extracted results as TXT or CSV.
Find and replace text using Regex.
Get code examples for popular programming languages.
Use ready-made patterns for common tasks.
No account or paid API required.
Frequently Asked Questions
Is this Regex Tester free?
Yes. You can use HoxTools Regex Tester and Text Extractor for free without creating an account.
Can I extract email addresses from text?
Yes. Select the Email pattern to find basic email address matches in your text. This does not verify whether an email address exists.
Can I extract phone numbers and URLs?
Yes. Choose the Phone or URL preset to find matching sequences in your text. Results depend on the selected pattern.
Can I download extracted results?
Yes. You can copy results or download them as TXT and CSV files.
Does this tool send my text to a server?
No. Regex processing is performed locally in your browser. This tool does not upload your test text to its server.
Can I use generated patterns in PHP and Python?
Yes. The tool provides basic code examples for JavaScript, PHP and Python. Some patterns may need language-specific adjustments.
What does the global flag do?
The global flag searches for all matches instead of stopping after the first match.