URL extractor for text and HTML
This URL extractor finds every web address in the text you paste and returns them as a list. It handles plain text such as e-mails, chat exports, documents and log files, as well as HTML source code, where it also reads the href, src and srcset attributes. Use it to collect the links from a newsletter, list the images a page loads, check the links in a document or gather the domains mentioned in a report.
What it finds
- Addresses starting with
http://,https://orftp://. - Addresses starting with
www., even without a scheme. A www. that is part of an e-mail address is ignored. - With Relative links in href/src ticked: relative paths in href, src, srcset, action, poster and data-src attributes, such as
/aboutorimg/logo.png. Anchors (#top), mailto:, tel:, javascript: and data: values are skipped.
Bare domains without www. or a scheme, such as example.com in a sentence, are not detected. That avoids treating file names like report.pdf or version numbers as links.
Example
Release notes (https://example.com/blog/release-2.4).
Wiki: https://en.example.org/wiki/Markup_(computing).
<a href="https://shop.example.com/cart?item=42&qty=1">Buy</a>
Duplicate: https://example.com/blog/release-2.4.
gives
https://example.com/blog/release-2.4
https://en.example.org/wiki/Markup_(computing)
https://shop.example.com/cart?item=42&qty=1
The closing bracket and full stop after the first link belong to the sentence, so they are removed, while the brackets inside the wiki address are balanced and kept. The & HTML entity in the href becomes a plain &, and the duplicate is dropped.
Options explained
- Remove duplicates: keeps the first occurrence of each exact URL.
- Strip trailing punctuation: removes . , ; : ! ? quotes and unmatched closing brackets from the end of each URL. Turn it off if your URLs really end with such characters.
- Domains only: returns the host name of each URL, such as shop.example.com, in lower case. Combine with Drop www. and Remove duplicates to get a list of unique domains.
- Base URL: with relative links on, enter the address of the page the HTML came from and relative links become full URLs (for example, /contact on https://example.com/shop/ becomes https://example.com/contact). Leave it empty to list them as written.
- Order and Separator: keep the order of the text or sort A → Z or Z → A, and separate the results by new lines, commas, semicolons or spaces.
Links in Markdown, e-mails and chats
Markdown links such as [docs](https://example.com/docs) give just the address: the closing bracket has no opening one inside the URL, so it is removed. Plain-text e-mails often wrap links in angle brackets, <https://example.com/a>; the extractor stops at the bracket. Quotes and backticks end a URL too, so links inside code samples come out clean.
How duplicates are compared
Remove duplicates compares the full URLs exactly. https://example.com/a and https://example.com/a?utm_source=news are different addresses and both stay, as do the http and https versions of the same page. If you only care about which sites are linked, switch on Domains only: then every link to the same host collapses into one line.
Next steps with your list
To see the parts of a single address – protocol, host, path and query parameters – paste it into the URL Parser. To sort a combined list from several pages, use Sort Text Lines, and to get the readable text of an HTML page without its tags, use the HTML Stripper. The extraction runs in your browser, so the text and HTML you paste are not uploaded.