URL parser and validator
Break a URL into scheme, host, port, path, query and fragment, and see why an invalid one is invalid. Handles IDN hosts, repeated parameters and odd schemes.
Every component, including the ones that are easy to miss
Scheme, credentials, host, port, path, query and fragment — plus the details that usually get lost: whether the fragment is absent or present-but-empty, whether the port is written or implied, and whether the host is internationalized.
Why an invalid URL is invalid
The browser's own parser throws a single TypeError: Invalid URL for every failure, which tells you nothing. The three that account for almost everything:
- No scheme.
example.com/xis not a URL, it is a string that looks like one. Tick the assume-httpsbox and it becomes one. - A space. Usually a line wrap in whatever you copied from. Spaces must be
%20. - An unencoded character in the host. Hosts have a much narrower character set than paths, and an underscore or an accent that is fine in a path is fatal in a hostname.
Credentials in a URL
https://user:pass@example.com is still valid syntax, and still a bad idea: the whole URL lands in server logs, browser history, and the referrer header of every outbound link on the page. If this tool shows a password field, treat that credential as compromised.
Related tools
- URL normalizerPut a URL in canonical form: default ports, percent-encoding, trailing slashes, parameter order and www. Choose a lossless or a comparison-grade normalization.
- Punycode and IDN converterConvert an internationalized domain to its xn-- punycode form and back. Shows each label separately, so you can see which part of the host is encoded.
- Query parameter editorEdit URL query parameters in a table. Repeated keys stay repeated — ?a=1&a=2 is two rows, not one, which is where most other editors quietly lose data.