Extract Emails from Text
Paste any text and every email address in it appears in the result box, one per line, with duplicates removed. Sort them, lowercase them, keep one domain, or join them with commas or semicolons to paste into a mail program.
0 words 0 characters 0 lines
Continue with this text: Remove duplicatesSortComma list
Your text stays in your browser: nothing is uploaded or stored on a server.
How to use the email extractor
- Paste your text into Your text, or use Open file for a .txt, .csv, .html or similar file. Click Example to see a sample.
- Read the result. Addresses appear in the Result box as you type, in the order they occur in the text. The status line shows how many there are, for example 3 addresses (4 found).
- Set the options: Remove duplicates (on by default), Sort A–Z, Lowercase, Only this domain and One per (Line, Comma or Semicolon). The tool remembers your choices next time.
- Copy or download the list with Copy or Download .txt, or click Use as input to keep working on it.
The options
| Option | What it does | Example |
|---|---|---|
| Remove duplicates | Keeps the first occurrence of each address. Comparison ignores upper and lower case in the whole address. | [email protected] [email protected] → [email protected] |
| Sort A–Z | Sorts alphabetically, ignoring case, instead of keeping text order. | Adam@… comes before bob@… |
| Lowercase | Converts every address to lowercase before duplicates are removed. | [email protected] → [email protected] |
| Only this domain | Keeps addresses whose domain is exactly what you type or a subdomain of it. A leading @, *., . or https:// is ignored, and case does not matter. |
corp.example.com keeps [email protected] |
| One per | Puts each address on its own line, or joins them with , or ; . |
[email protected], [email protected] |
Domain matching works on whole labels, so example.com keeps [email protected] and subdomains such as [email protected], but not [email protected] or [email protected]. International domains match whether you type them in Unicode or in the xn-- form. Typing just co.uk or com keeps every address under that ending; .co.uk and *.co.uk work the same way, so [email protected] [email protected] with .co.uk gives [email protected].
What counts as an email address
The pattern is practical rather than a full implementation of the email standards: it finds the addresses people actually paste from documents, exports and web pages. An address needs:
- a local part (before the
@) made of letters, digits and. _ % + -, with no dot at the start or end and no two dots in a row; an apostrophe between two letters or digits also counts, as ino'[email protected]; - a domain made of labels separated by dots, where each label starts and ends with a letter or digit and may contain hyphens;
- a top-level domain of at least two letters, such as
.com,.io,.museumor.photography.
Letters from any alphabet count, so josé@exämple.de and 用户@例子.广告 are found. Surrounding punctuation is left out: brackets, angle brackets, quotes, commas, semicolons and colons around an address are not part of it, and a period that ends the sentence is removed. A mailto: prefix, anything after a ? and leading percent-encoded bytes (mailto:%[email protected] gives [email protected]) are dropped too.
| Text | Result | Why |
|---|---|---|
Questions? [email protected]. |
[email protected] |
The final period ends the sentence. |
name@localhost |
nothing | No top-level domain. |
[email protected] |
nothing | The top-level domain has one letter. |
[email protected] |
nothing | A domain label cannot start with a hyphen. |
[email protected] |
nothing | The top-level domain contains a digit. |
user@[192.168.0.1] |
nothing | IP-address domains are not supported. |
'[email protected]' |
[email protected] |
Quotes around the address are not part of it. |
[email protected] |
nothing | Image file endings are not top-level domains. |
https://user:[email protected]/ |
nothing | The user name and password in a link are not addresses. |
anna.lee@↵example.com |
nothing | The address is split by a line break. |
Examples
A contact list copied from a spreadsheet, with Sort A–Z, Lowercase and One per: Comma. Two rows hold the same address with different capitals, so the status shows 3 addresses (4 found):
Name Email Company
Maria Lopez [email protected] Acme
Tom Hart [email protected] Acme
maria lopez [email protected] Acme
Jin Park [email protected] Partner
[email protected], [email protected], [email protected]
Email headers with Only this domain set to corp.example.com. The vendor address is filtered out and the capitalized copy of Lee’s address is removed as a duplicate (2 addresses (4 found)):
From: Lee <[email protected]>
To: [email protected], [email protected]
Cc: [email protected]
[email protected]
[email protected]
An email footer with One per: Semicolon (Outlook). Plus addressing such as +orders is kept, because it is part of the address:
[email protected]; [email protected]; [email protected]
When people use it
- Building a mailing list from a CRM or form export. Paste the CSV or the copied columns, keep Remove duplicates on and use Lowercase so the same person is not added twice with different capitals.
- Collecting the addresses from an email thread. Paste the headers or a forwarded chain and filter by your company’s domain to see only internal people, or by a client’s domain to see theirs.
- Getting contacts out of a PDF or a web page. Copy the text of a conference attendee list, a staff directory or a document and extract the addresses in one go.
- Checking a document before you share it. Paste a report or a data file to see whether it contains any personal email addresses you did not mean to include.
To clean a list further, the remove duplicate lines tool has more matching options, and sort lines offers other sort orders. For web links in the same text, use the URL extractor. The guide how to extract emails and URLs from large text files covers working with big exports.
Known limits
The extractor errs toward finding plain, common addresses. A few rare or tricky cases come out differently from what you might expect, so check the result when they apply:
- Unusual characters before the @. The HTML standard’s definition of a valid email address also allows characters such as
!,#and=in the local part. This tool treats them as separators, because text such as[email protected]is far more common, and returns only the part after such a character:[email protected]gives[email protected]. Quoted local parts such as"john doe"@example.comare not supported either. - Image file names. Names ending in an image extension (.png, .jpg, .jpeg, .gif, .svg, .webp, .avif, .bmp, .ico, .tif, .tiff) are skipped, so
[email protected]is not listed and is not counted in found. - Obfuscated addresses written as
name [at] example [dot] comorname(at)example.comare not decoded. - Missing spaces. If a PDF or web page loses the space after an address, as in
[email protected], the next word becomes part of the domain.
Long texts are fine: extracting 100,000 addresses from one paste took under a second in a test of the same code, and Open file accepts files up to 20 MB.
Questions
Is my text uploaded anywhere?
No. The extraction runs in your browser with JavaScript; nothing is sent to a server. The text is kept only in this browser tab so it is still there if you open another tool, and it is gone when you close the tab.
How do I extract email addresses from an Excel or Google Sheets file?
Select the column (or the whole sheet), copy it and paste it here. Cells arrive separated by tabs and line breaks, which the extractor treats like spaces, so the other columns are simply ignored. You can also save the sheet as CSV and use Open file.
Can I extract emails from a PDF?
Open the PDF, select all the text, copy it and paste it here. The Open file button reads plain-text files such as .txt and .csv, not .pdf. If an address was split across two lines in the PDF, it is not found; join the line first, or clean up the whole text with remove line breaks.
Why do I see "3 addresses (4 found)"?
The first number is how many addresses are in the result; the number in brackets is how many matches were in the text before duplicates were removed and the domain filter was applied.
Are duplicates with different capitals removed?
Yes. [email protected] and [email protected] count as the same address, and the first spelling in your text is kept. Tick Lowercase to output every address in lowercase.
How do I paste the list into Outlook or Gmail?
Choose Comma or Semicolon (Outlook) in One per, copy the result and paste it into the To, Cc or Bcc field. For a large mailing, use Bcc so recipients do not see each other's addresses.
Does it find addresses written as "name [at] example [dot] com"?
No. Obfuscated addresses are skipped on purpose, because "at" and "dot" also appear in ordinary sentences. Only addresses with a real @ sign are extracted.