Extract emails and URLs
Pull every email address and web link out of a text, and optionally IPv4 addresses and hashtags.
Input
Result
Fill in the input and press Run.
Your input is processed in memory and then discarded. It is not stored or logged. Even so, don't paste live passwords or keys into any online tool.
Use it from code or an agent
curl -s https://setget.net/v1/tools/extract-emails-urls \
-H 'Content-Type: application/json' \
-d '{"input":{"text":"Mail [email protected] or [email protected], see https://example.com/docs."}}'
import json, urllib.request
body = {'input': {'text': 'Mail [email protected] or [email protected], see https://example.com/docs.'}}
request = urllib.request.Request("https://setget.net/v1/tools/extract-emails-urls", json.dumps(body).encode(),
{"Content-Type": "application/json"})
print(json.load(urllib.request.urlopen(request))["result"])
const response = await fetch("https://setget.net/v1/tools/extract-emails-urls", {
method: "POST",
headers: {"Content-Type": "application/json"},
body: JSON.stringify({"input":{"text":"Mail [email protected] or [email protected], see https://example.com/docs."}}),
});
console.log((await response.json()).result);
Tool: run_tool
Arguments:
{
"slug": "extract-emails-urls",
"input": {
"text": "Mail [email protected] or [email protected], see https://example.com/docs."
}
}
{
"input": {
"text": "Mail [email protected] or [email protected], see https://example.com/docs."
}
}
Endpoint: POST /v1/tools/extract-emails-urls. Over MCP: run_tool with slug: "extract-emails-urls".
Machine-readable: input schema, Markdown. Connect an agent.
Inputs
| Name | Type | Required | What it does |
|---|---|---|---|
text |
string | yes | The text to search. |
include_ips |
boolean | no | Also list IPv4 addresses. Default: false. |
include_hashtags |
boolean | no | Also list hashtags such as #news. Default: false. |
Examples
Input
{
"text": "Mail [email protected] or [email protected], see https://example.com/docs."
}Result
{
"emails": [
"[email protected]",
"[email protected]"
],
"urls": [
"https://example.com/docs"
],
"count": 3
}With IP addresses and hashtags
Input
{
"text": "Server 10.0.0.5 is down (www.example.com/status) #outage #outage",
"include_ips": true,
"include_hashtags": true
}Result
{
"emails": [],
"urls": [
"www.example.com/status"
],
"ips": [
"10.0.0.5"
],
"hashtags": [
"#outage"
],
"count": 3
}Questions
- Which links are found?
- Links that start with http://, https://, ftp:// or www. A bare domain such as "example.com" is not listed.
- Are duplicates removed?
- Yes. Each value is listed once, in the order it first appears.
- Does it check that an address really exists?
- No. It only looks at the shape of the text and never contacts the network.
Related tools
- PII redactorReplace emails, phone numbers, card numbers, IP addresses and IBANs in text with placeholders such as [EMAIL].
redact-pii - Regex extractorPull every match of a regular expression out of text as a simple list, or just one capture group.
regex-extract - URL parserSplit a URL into scheme, login, host, port, path, query parameters and fragment.
url-parse - Apply a patchApply a unified diff to a text and get the patched result, with clear errors when a hunk does not fit.
patch-apply - Case converterConvert text between lower, UPPER, Title, Sentence, camelCase, PascalCase, snake_case, kebab-case and more.
case-convert - Escape and unescape textEscape or unescape text for HTML, URLs, JSON strings, shell commands, regular expressions and CSV fields.
escape-unescape