A server only your machine can reach

A server on 127.0.0.1 is a complete deployment, and the addresses it hands out are built so they still mean something on somebody else's machine.

A server on the machine your browser is on can listen on 127.0.0.1, where nothing else can reach it — and that is a complete deployment, not a step before a real one. The question it raises is what happens to an address it prints once that address leaves the machine.

What loopback means

An address like 127.0.0.1 is not a place. It names whichever machine reads it: in your browser it is your machine, and sent to somebody else it names theirs. The server binds loopback unless you tell it otherwise.

Where that matters

A connection string carries the address the server bound, so it only works in a browser on the server’s own machine until you say which address the browser reaches it at. Learn more about an address your browser can reach.

A link to a comment on such a server is built on this site’s address instead. Sent to somebody else, a 127.0.0.1 link would reach their own server, which would answer that it has never heard of the thread. This site serves the page for every server and is still never told which server or which thread. Learn more about links to a comment.

Next steps

  • Manage a server: reach it from another browser, by a forwarded port or behind a proxy.
  • Connect to a server: pass the port you reach the server on when you mint a connection string.
Documentation

Type to search…

↑↓ navigate↵ selectEsc close