Home/Blog/How to Extract URLs and Links from Any Text

How to Extract URLs and Links from Any Text

Pull all web links from documents, emails, chat logs, and HTML source code using a free tool.

2026-03-16Extract Data

Links get scattered across emails, documents, chat logs, and web pages. Collecting them manually is tedious. The Extract URLs tool scans any text and pulls out every HTTP and HTTPS link into a clean, deduplicated list.

Where Links Hide

URLs appear in email threads (meeting links, shared docs, reference links), Slack and Teams chat exports, research documents with citations, HTML source code, and bookmark exports. Paste any of these into the tool and extract all links instantly.

How It Works

The tool matches all standard URL patterns starting with http:// or https://. It handles query strings, fragments, paths, and ports. Results are deduplicated so each unique URL appears only once.

For HTML Source

If you're extracting links from HTML, you can also use the Extract Links from HTML tool, which specifically pulls href attributes. This catches relative URLs that the general URL extractor might miss.

Pipeline Example

For a research workflow: paste a document, Extract URLs to get all links, then use your browser to check each one. For chat logs, combine with Normalize Whitespace first to clean up formatting before extraction.

Try it now — paste your text below

Everything runs locally in your browser. No data is stored.

Extract URLs

Find and extract all HTTP and HTTPS URLs from any text. Useful for collecting links from documents, emails, or chat logs.

Example

Input

Visit https://example.com and http://test.org/page for details.

Output

https://example.com
http://test.org/page

How Extract URLs Works

Find and extract all HTTP and HTTPS URLs from any text. Useful for collecting links from documents, emails, or chat logs.

This tool runs entirely in your browser — no data is sent to any server. Paste your text, click Run, and get your result instantly. You can also chain this tool with others using the pipeline feature: run Extract URLs, then continue with a related tool to build a multi-step text workflow.

TextRefinery is a free, open-source text processing toolkit. Learn more about regular expressions and text processing on the web.

TextRefinery — Browser-first text transformation tools. All processing happens locally in your browser.