Skip to content
UniKit

URL parser

Break a URL into protocol, credentials, host, port, path, query parameters and hash. Query parameters are shown in a table you can edit and the URL is rebuilt live.

Runs in your browserEvery computation happens in your browser — your data never leaves this device.

URL

Parsed result

Protocolhttps:
Usernameuser
Passwordpass
Hostexample.com:8443
Hostnameexample.com
Port8443
Path/path/to/page
Hash (fragment)#section
Originhttps://example.com:8443

Query parameters

Parameters: 3

NameValueActions

Rebuilt URL (encoded)

https://user:pass@example.com:8443/path/to/page?name=%E4%BD%A0%E5%A5%BD&lang=zh&lang=en#section

What this tool does

  • Break a long URL into its protocol, hostname, port, path and fragment without hunting for question marks and hashes by eye.
  • Check query parameters: repeated keys such as lang=zh&lang=en are listed one by one, keeping the original order and the original encoding — nothing is deduplicated or rewritten.
  • Edit a parameter and get the rebuilt URL immediately: change a value, add or remove a parameter, and the result updates live and can be copied.
  • Debug “my parameter is ignored”: enable “decode query values” to see whether %E4%BD%A0%E5%A5%BD is 你好 and whether + is really a space.

Example

Input

https://example.com:8443/path/to/page?name=%E4%BD%A0%E5%A5%BD&lang=zh&lang=en#section

Output

Protocol: https:
Username: (empty)
Password: (empty)
Host: example.com:8443
Hostname: example.com
Port: 8443
Path: /path/to/page
Hash (fragment): #section
Origin: https://example.com:8443
Query parameters (3): name = %E4%BD%A0%E5%A5%BD, lang = zh, lang = en
Rebuilt URL: https://example.com:8443/path/to/page?name=%E4%BD%A0%E5%A5%BD&lang=zh&lang=en#section

The parameter table shows the raw form (%E4%BD%A0%E5%A5%BD) by default; tick “decode query values” to see 你好. The duplicate lang key stays as two separate rows and is written back in its original order.

Frequently asked questions

Why is a parameter value shown as a pile of %E4%BD%A0?

That is the raw URL-encoded form. The table keeps it untouched so rebuilding never double-encodes. Tick “decode query values” to read it as text (%E4%BD%A0%E5%A5%BD → 你好, + → space).

Are duplicate parameters such as ?a=1&a=2 merged?

No. Every key/value pair stays on its own row in the original order and is written back verbatim. Backends disagree about duplicates — some take the last value, some collect an array — so preserving the raw structure shows what was really sent.

Can I parse just example.com without a scheme?

Yes. A missing scheme is treated as https://, so example.com/path works too. An empty hostname or a clearly malformed value (for example one containing spaces) reports “not a valid URL”, and empty input asks for a URL.

Why did a path with Chinese characters become percent-encoded?

Parsing uses the browser’s built-in URL parser, which normalises non-ASCII characters in the path to UTF-8 percent encoding — that is what the WHATWG URL standard specifies. Parameter values are unaffected and are still shown in their raw form.

Is it safe to paste a URL containing credentials?

Parsing happens entirely in your browser: no network request is made and the input is never logged. Still, since URLs can carry credentials, avoid leaving them in a shared clipboard for long.

Keywords:urlurl 解析query string查询参数url parserparse url链接解析uriquerystring

Related tools