URL Parser
Break an absolute URL into its protocol, host, path, and query fields.
Your result will appear here…
How to use URL Parser
- Paste an absolute URL that starts with a scheme such as https://.
- Select Parse.
- Read each component, and paste the query into Query String Parser if you need its parameters.
Example
Input / settings:
https://example.com:8443/docs/tools?tag=web&tag=dev#examples
Output:
Protocol: https: Hostname: example.com Port: 8443 Pathname: /docs/tools Query: tag=web&tag=dev Fragment: #examples
The query is shown without its ?, while the fragment keeps its #.
When to use
- Check which host, port and path a redirect or webhook URL really points to.
- Spot an unexpected port or fragment in a copied link.
- See how an address with non-ASCII characters is encoded before it is sent.
Overview
URL Parser splits an absolute URL into protocol, hostname, port, path, query and fragment with the browser's own URL parser, the same algorithm browsers use for links. The result is normalized, so it can differ from what you typed: the host is lowercased, default ports are dropped, dot segments are resolved and unsafe characters are percent-encoded. The tool reads the text only and never requests the address.
Supported input
absolute URL
Output details
URL components
Limitations
- Requires an absolute URL with a scheme. Relative URLs and addresses without a scheme are rejected.
- The result is normalized by the browser URL parser. Credentials are not shown and an empty query or fragment cannot be told from a missing one.
Common mistakes
- A scheme is required. example.com/path, //example.com/x and /relative/path are rejected; add https:// in front.
- The output is normalized, not echoed. HTTPS://Example.COM:443/A/../b/./c d gives hostname example.com, an empty port and the path /b/c%20d.
- Credentials in a URL are not shown. https://user:[email protected]/p is parsed, and the user name and password are left out of the output.
- The query and fragment appear percent-encoded, not decoded: x=1 2 is shown as x=1%202. Decode them with Query String Parser or URL Decoder.
- An empty query or fragment looks the same as a missing one: https://example.com? and https://example.com# give the same output as https://example.com.
- Other schemes are accepted too. mailto:[email protected] has no hostname, its address appears under Pathname, and javascript:alert(1) is parsed as text and never run.
Practical tips
- Read the Port line before you trust a link. A port is listed only when it differs from the scheme's default, so 8443 appears for https but 443 does not.
- An internationalized hostname is shown in its ASCII form: münchen.de becomes xn--mnchen-3ya.de.
Privacy and security
This tool runs entirely in your browser. Your input is never uploaded to our servers. Parsing runs locally and the address is never requested, so pasting a suspicious link does not visit it. Reading the real hostname helps you spot look-alike addresses, but parsing cannot tell you whether a site is trustworthy.
References
Frequently asked questions
Why is the port empty?
The port is shown only when it is not the default for the scheme. https://example.com:443/ and http://example.com:80/ both give an empty port.
Why does the hostname differ from what I pasted?
The parser lowercases the host and converts non-ASCII names to their ASCII form, so Example.COM becomes example.com.
Can I paste a relative URL?
No. Without a scheme the tool cannot tell which site the path belongs to, so it asks for an absolute URL.