Interactive URL anatomy

Localhost URL Explainer

See exactly what a local URL means to the browser—and which parts affect the network request, origin, route, and page state.

URLs are parsed by your browser and are not requested or uploaded.

Enter a URL

Absolute and relative URLs are supported.

Used only when the first value begins with /, ?, #, ./, or ../.

URL breakdown

Valid localhost URL

Three localhost URL rules that prevent common mistakes

Origin

The port is part of security identity

http://localhost:3000 and http://localhost:5173 are different origins even on the same computer.

Request target

The fragment stays in the browser

The server receives the path and query string, but the #fragment is handled by the browser and client-side code.

Binding

0.0.0.0 is not a normal destination

Applications bind to 0.0.0.0 to listen on IPv4 interfaces. Clients should normally use localhost, 127.0.0.1, or a real interface address.

Use the result

Once the hostname and port are clear, generate a listener or HTTP check with the Port Command Generator. If the compared origins differ, inspect the response with the CORS Header Analyzer.

Reference

Parsing follows the browser URL model documented in the WHATWG URL Standard.