SvelteKit — “Problem loading page” on Firefox
May 25, 2023
I recently started learning SvelteKit, but ran into an unexpected issue when I ran the server:
Unable to connect
Firefox can't establish a connection to the server at localhost:5173
Oddly, the URL worked fine on Chrome and Edge, but failed in Firefox, even when I went into incognito mode or cleared the browser cache.
Solution
What worked for me was the following:
- Go to
about:config
to view Firefox settings. - Search for the
network.dns.disableIPv6
setting, and make sure it’s set to false.
If that doesn’t work, you can also try checking about:serviceworkers
for localhost
and unregister any that appear (thanks to grygrflzr
in the Svelte for this one!).