🧩

URL Parser

✓ Free & no signup 🔒 Runs 100% in your browser Updated 2026-11-25 Website Management Tools

Long URLs hide their structure in plain sight. A marketing link with three tracking parameters, an API endpoint with encoded characters, a link that stopped working after a CMS migration: all of them become easy to read the moment you split them into their named parts. This tool does exactly that. Paste any URL and it breaks out the protocol, credentials, host, port, path, every query parameter in a table, and the fragment, instantly, entirely in your browser with nothing uploaded.

The parser uses the same URL API your browser itself uses, so the output matches what a browser or server actually sees rather than what a quick glance suggests. That distinction matters more than people expect, because the URL grammar has rules most readers have never fully internalized: what the first slash really starts, how query strings are separated from fragments, what happens when special characters are percent-encoded, and how default ports quietly disappear.

This page also serves a debugging purpose. When a tracking link misfires, an API call returns unexpected data, or a redirect chain loses a parameter, the fastest first step is seeing the URL decomposed into its exact components, and that is precisely what this tool gives you.

The Parts of a URL, Named Exactly

Every component has a formal name from the URL standard, and knowing the names makes documentation, bug reports, and conversations with other developers precise. Take this deliberately busy example:

https://user:pass@shop.example.com:8443/products/list?category=shoes&sort=price&page=2#reviews

ComponentValue in the exampleWhat it is
Protocol (scheme)httpsHow to talk to the resource; ends at the colon
Credentialsuser:passOptional userinfo before the at-sign; rare and discouraged
Hostshop.example.comThe server, as a domain or IP address
Port8443Optional; defaults to 443 for https and 80 for http
Path/products/listResource location on the server; starts at the first slash after the host
Querycategory=shoes&sort=price&page=2Parameters after the question mark, pairs joined by ampersands
Hash (fragment)reviewsAfter the hash; client-side only, never sent to the server

The tool shows each of these separately, and additionally computes the origin, the combination of protocol, host, and port that browsers use for security decisions. Two URLs with different origins are treated as different sites by the same-origin policy, which is why origin, not just domain, appears in CORS errors and cookie rules.

How to Use This Tool (Step by Step)

  1. Paste the complete URL, including the scheme. If you omit https://, many parsers misread the whole string as a path; this tool flags incomplete input rather than guessing.
  2. Read the component breakdown, which updates as you type.
  3. Inspect the query parameter table: each parameter appears on its own row with its decoded value, so percent-encoded characters like %20 for space and %2F for slash are shown as the characters they represent.
  4. Copy any individual component, or the decoded query string, for use in bug reports, tests, or documentation.
  5. Paste a second URL to compare, which is often how you spot the exact parameter that differs between a working link and a broken one.

Debugging Tracking Links: A Worked Example

Marketing URLs accumulate parameters from multiple tools, and when attribution breaks, the culprit is usually visible in the decomposition. Consider a real-shaped example:

https://store.example.com/sale?utm_source=newsletter&utm_medium=email&utm_campaign=black-friday&utm_content=hero-banner&gclid=Cj0KCQj&fbclid=IwAR3x&utm_source=newsletter-2

Parsed carefully, three problems jump out immediately, and all three are classic:

  • Duplicate parameter: utm_source appears twice, once as newsletter and again as newsletter-2. Servers behave unpredictably with duplicates: some take the first value, some the last, and some concatenate. Whatever your analytics platform does becomes an invisible attribution bug.
  • Empty value: gclid, the Google Ads click identifier, has an equals sign but nothing after it. A click landed but the value was lost upstream, often by a redirect that dropped or truncated parameters.
  • Mixed naming case: if any parameter had been written UTM_Source or utm_Source, it would count as a different parameter on case-sensitive servers. URL parameter names are case-sensitive by convention and by default.

Comparing a working click's URL against a broken click's URL in this tool, side by side, typically localizes the failure in seconds: which hop in the redirect dropped the parameter, which value got encoded twice, which name drifted in case.

Rules People Get Wrong: Encoding, Case, and Defaults

Three areas of the URL grammar produce most real-world confusion, and each has rules worth stating precisely:

Percent-encoding. Characters that would break the URL grammar, such as spaces, ampersands inside values, and non-ASCII text, are encoded as a percent sign plus two hex digits. A space becomes %20, a literal ampersand inside a parameter value becomes %26, and the em dash becomes %E2%80%94 in UTF-8. The double-encoding trap is the one to watch: %2520 is the encoding of the literal text %20, not of a space, so decoding twice when something was encoded once turns correct values into garble. The tool decodes once, the standard behavior, and shows the raw form separately.

Case sensitivity. The scheme and host are case-insensitive, so HTTPS://EXAMPLE.COM works identically. Everything after them, path, query names, query values, is case-sensitive on most servers by default. A route written /Users and requested as /users is a different resource unless the server normalizes it.

Default ports and trailing slashes. https on port 443 and http on port 80 omit the port entirely, and https://example.com and https://example.com/ are the same resource for most purposes, with the browser filling in the slash. But the same equivalence does not extend to paths with different content, and origin comparisons treat an explicit :443 as identical to its omission because it is the default.

Practical Uses Beyond Debugging

  • API endpoint inspection: paste a REST endpoint to see which parameters it takes, which values are encoded, and exactly what the path segments are, especially when chaining calls or writing tests.
  • Understanding short-link destinations: expand and decompose a redirect target before clicking, checking the real domain and parameters rather than trusting the display text.
  • Teaching and documentation: the named-component table is a reliable reference when writing onboarding docs or explaining URLs to non-developers.
  • Security review: spotting credentials in URLs, which is a genuine anti-pattern since URLs land in server logs and browser history, and noticing open-redirect parameters like ?url=http://untrusted.example before they bite.
  • Data cleaning: extracting the bare destination from a link covered in tracking parameters, for sharing or archiving.

Edge Cases the Parser Handles Honestly

Some inputs are not valid URLs, and a parser that guesses anyway produces misleading output. This tool reports the specific problem instead: a missing scheme, an invalid host, a port outside the valid range, or a malformed IPv6 literal. It also handles the less common shapes correctly, such as IPv6 hosts in square brackets like http://[2001:db8::1]:8080/, userinfo with encoded characters, and empty query strings where the question mark is present but carries no parameters. That last distinction matters in some server frameworks, which treat ? as present-but-empty differently from absent entirely.

Tips and Best Practices

  • Always include the scheme when pasting; the tool will flag its absence rather than silently misparsing the rest.
  • When comparing two URLs, decompose both and diff the tables rather than eyeballing the raw strings; a single changed character hides easily in a 200-character link.
  • Check for credentials before sharing a URL publicly; user:pass@host links still appear in the wild and leak secrets into every log that touches them.
  • Remember the fragment never reaches the server, so single-page app routes that live after the hash cannot be tracked server-side.
  • When building URLs programmatically, encode parameter values individually rather than encoding the whole string, which produces double-encoded output.
  • For tracking links specifically, decide on one canonical parameter order and casing convention across your team; consistency makes future diffs trivial.

Frequently Asked Questions

What is the difference between a URL's query string and its fragment?
The query string starts at the question mark and ends at the first hash; it is sent to the server with every request, so servers and analytics platforms can read and act on it. The fragment starts at the hash and is client-side only: the browser never transmits it, using it to scroll to a page anchor or, in single-page apps, to hold the client-side route. A practical consequence: you cannot log or track fragments server-side, and any parameters that must affect the server response must live in the query string, not after the hash.
Why are my URL parameters showing as percent-encoded garbage?
Reserved and non-ASCII characters must be percent-encoded to survive the URL grammar: spaces become %20, slashes inside values become %2F, and non-Latin text becomes multi-byte UTF-8 sequences like %E2%80%94. The tool decodes each parameter value once and shows it as readable text. If your value still looks encoded after decoding, it was probably encoded twice: %2520 is the literal text %20 re-encoded, not a space. Double-encoding usually happens when a value passes through two encoding layers, such as a template plus a redirect, and the fix is encoding only once, at the final step.
What does origin mean in a URL, and why does it matter?
Origin is the combination of scheme, host, and port, such as https://shop.example.com:8443, and it is the identity browsers use for the same-origin policy. Two URLs sharing a domain but differing in scheme or port have different origins, so http and https on the same host are separated, as are different ports. Cookies, CORS rules, and script access all key off origin rather than domain. That is why CORS errors mention origins explicitly and why this tool displays the computed origin alongside the individual components: many cross-origin bugs are simply an overlooked port or scheme mismatch.
How do I debug a broken tracking or UTM link?
Decompose the URL and look for the classic failures: duplicate parameters like utm_source appearing twice, since servers pick a winner unpredictably; empty values like gclid= with nothing after the equals sign, usually lost in a redirect hop; casing drift such as UTM_Source, which counts as a different parameter because names are case-sensitive; and values that need decoding but were double-encoded. Comparing a working click's URL against a broken one in the parser, component by component, localizes exactly which parameter broke and where in the chain it happened.
Is the port part of the URL if it is not written?
It is always defined, just implicit. HTTPS defaults to port 443 and HTTP to port 80, and browsers omit the number from the address bar when it matches the default. So https://example.com and https://example.com:443/ are the same origin and the same resource. When a server listens on a non-default port such as 8443 or 3000, the port must appear explicitly in the URL, and omitting it sends the request to the default port where nothing may be listening, producing a connection error that looks like a server outage rather than a URL typo.
Can credentials appear in a URL, and is that safe?
The grammar allows userinfo before the host, as in https://user:pass@example.com/, and some tools still generate such links. It is unsafe and discouraged: URLs are logged by servers, proxies, and browsers, they appear in history and referrer headers, and anyone who sees the link has the credential. If you find one with this parser, treat the credential as exposed and rotate it. Modern practice moves authentication into headers, tokens, or POST bodies, and browsers have further limited inline credentials by ignoring them for most navigation contexts, but the links still surface in legacy systems and integrations.

Related Tools