Email & Phone Extractor
Pull structured values out of unstructured text: email addresses, phone numbers, URLs, domains, IPs, hashtags, numbers and dates — deduplicated, sorted and ready to export.
Photo by Carlos Muza on Unsplash
Data extraction tool
Key takeaways
- Email extraction optimises for finding what a human would recognise, not for enforcing the full RFC 5322 grammar.
- Phone matching removes emails and URLs first, because their digit runs otherwise produce false positives.
- Harvesting addresses from third-party sites for unsolicited mail is prohibited under CAN-SPAM and needs consent under GDPR.
What each mode matches
| Mode | Pattern behaviour |
|---|---|
| Email addresses | Local part, @, domain with a 2–63 character TLD. Deliberately permissive on the local part, since the full RFC 5322 grammar allows almost anything. |
| Phone numbers | Optional country code, optional area code in parentheses, then 7–15 digits with any common separator. Emails and URLs are removed first so their digits do not create false matches. |
| URLs | http and https URLs, stopping at whitespace, quotes or closing brackets. |
| Domains | Bare hostnames, including those pulled out of email addresses. |
| IP addresses | IPv4 with proper 0–255 range validation per octet. |
| Hashtags & mentions | Tokens starting with # or @, 2–50 word characters. |
| Numbers | Integers and decimals, with thousands separators. |
| Dates | ISO 8601, slash and dot formats, and English month-name formats. |
Why email matching is approximate
RFC 5322 defines an email grammar so permissive that "very.unusual.@."@example.com is technically valid. A regex that accepts everything valid and nothing invalid runs to hundreds of characters and still cannot check whether the mailbox exists.
This tool therefore optimises for extraction rather than validation: it finds the addresses a human would recognise in a document. If you need real validation, the only reliable method is to send a confirmation message. Syntactic checks should be deliberately loose — rejecting valid addresses annoys real users far more often than accepting a malformed one costs you.
Obfuscated addresses such as name [at] example [dot] com will not match by design. That obfuscation exists specifically to defeat scrapers, and it is worth respecting.
Practical uses
- Log triage. Pull every IP or URL out of a log excerpt to build a list of affected hosts.
- Migration audits. Extract all links from an exported page to check which point at the old domain; the link extractor does this with anchor text and rel attributes.
- Contact cleanup. Pull addresses out of a pasted signature block or CSV, deduplicate, then load them into your CRM.
- Content analysis. Extract hashtags from social exports to see which campaign tags actually got used.
- Data validation. Extract every date from a document to spot inconsistent formats before importing.
Use it responsibly
Extracting contact details from text you already have is routine data hygiene. Harvesting addresses from third-party websites to send unsolicited mail is a different activity, and in most jurisdictions an illegal one.
- GDPR (EU/UK). An email address is personal data. Processing needs a lawful basis, and for marketing that normally means prior consent.
- CAN-SPAM (US). Section 5 explicitly prohibits sending to addresses obtained by automated harvesting from websites, with penalties per message.
- CASL (Canada). Requires express or clearly implied consent before commercial electronic messages.
Because everything here runs client-side, the tool cannot fetch a web page for you — it only processes text you paste in yourself. That is a deliberate design limit, not an oversight.
Frequently Asked Questions
How do I extract all email addresses from text?
Paste the text, keep the mode on “Email addresses” and the results appear instantly. Enable “Remove duplicates” and pick a separator that suits wherever you are pasting them next.
Does this validate that an address is real?
No. It finds strings that look like addresses. The only way to confirm a mailbox exists is to send it a confirmation message; syntax checks cannot tell you that.
Can it extract from a website URL?
No. The tool runs entirely in your browser and cannot fetch remote pages. Copy the text or view-source output and paste it in.
Why did it miss a phone number?
Phone formats vary enormously worldwide. The pattern requires 7 to 15 digits and accepts common separators, but unusual local conventions or numbers written in words will not match.
Is it legal to extract email addresses?
Extracting from your own data is fine. Harvesting addresses from websites for unsolicited marketing is prohibited by CAN-SPAM in the US and requires consent under GDPR in Europe.
Can I export the results?
Yes. Copy them in the separator of your choice, or download a CSV that includes the occurrence count for each unique value.
Sources & further reading
- RFC 5322 — the internet message format grammar that defines valid addresses
- FTC: CAN-SPAM compliance guide — the US rules on address harvesting and commercial email
- GDPR Article 6 — lawful bases for processing personal data such as email addresses
- MDN: Regular expressions — the pattern syntax behind every extraction mode