Ask coding questions

← Back to all posts
How do Ports Work in repl?
h
realTronsi

How do ports work in repl? The other day I tried forking one of my applications into repl for some testing purposes, but ports don't seem to work the same way.

Putting something like that wouldn't work, and I'm not sure if repl presets a port or has some other API I'm unaware about.

Voters
CoolChurro
justcobra123
cokie
realTronsi
Comments
hotnewtop
ironblockhd

Replit uses a proxy that forces anything on port 80 and only supports tcp, specify port 80 instead of 3000 in the client side

Coder100

Simply put, if your local project had: localhost:8080
In repl.it it becomes: [yourrepl].[yourname].[repl].[co]

If you had: 127.0.0.1:8080, you will need to change the IP to 0.0.0.0: 0.0.0.0:8080

Then: [yourrepl].[yourname].[repl].[co]

realTronsi

@Coder100 So there's no need for a port specification in repl?[yourrepl].[yourname].[repl].[co]

Coder100