Summary
On machines where Docker Desktop has modified the hosts file, localhost resolves to ::1 (IPv6) instead of 127.0.0.1 (IPv4). The studio server only binds to 127.0.0.1 by default, so navigating to localhost:8888 fails to reach the server while 127.0.0.1:8888 works fine. This affects all installs on Windows with Docker Desktop, not just --local.
Steps to reproduce
- Have Docker Desktop installed on Windows
- Install and start Studio (any install method)
Open localhost:8888 in browser - hits ::1 (IPv6), server not listening there, connection refused or stale cached page shown
- Open
127.0.0.1:8888 - works correctly
Root cause
studio/backend/run.py line 611 defaults host to "127.0.0.1". Docker Desktop comments out the default localhost entries in C:\Windows\System32\drivers\etc\hosts, causing Windows DNS to fall back to resolving localhost as ::1. The server is only listening on IPv4 so the connection fails.
Suggested fix
Change the default bind host from 127.0.0.1 to 0.0.0.0 so the server binds all interfaces and both localhost and 127.0.0.1 work regardless of how the OS resolves localhost.
Environment
Windows, Docker Desktop installed.
Summary
On machines where Docker Desktop has modified the hosts file,
localhostresolves to::1(IPv6) instead of127.0.0.1(IPv4). The studio server only binds to127.0.0.1by default, so navigating tolocalhost:8888fails to reach the server while127.0.0.1:8888works fine. This affects all installs on Windows with Docker Desktop, not just--local.Steps to reproduce
Open localhost:8888 in browser - hits ::1 (IPv6), server not listening there, connection refused or stale cached page shown
127.0.0.1:8888- works correctlyRoot cause
studio/backend/run.pyline 611 defaultshostto"127.0.0.1". Docker Desktop comments out the default localhost entries inC:\Windows\System32\drivers\etc\hosts, causing Windows DNS to fall back to resolvinglocalhostas::1. The server is only listening on IPv4 so the connection fails.Suggested fix
Change the default bind host from
127.0.0.1to0.0.0.0so the server binds all interfaces and bothlocalhostand127.0.0.1work regardless of how the OS resolveslocalhost.Environment
Windows, Docker Desktop installed.