Sometimes you need to test some functionality on mobile device but from the website which is running on your laptop. There is a simple solution - SOCAT.
DDEV is a great tool for local development and currently I'm using it on some of projects. It has internal command to share website over internet with ngrok

But it's not the case for local development. There is simplier:
Install socat. I have "socat version on Feb  4 2021 12:53:19"

sudo apt install socat

Then check your internal IP:


run website and check it's port

ddev start
ddev status

run socat
socat tcp-listen:PORT_LISTEN,reuseaddr,fork tcp:localhost:PORT_WEBSITE

something lke that

socat tcp-listen:8181,reuseaddr,fork tcp:localhost:49259

And here you go, open web browser on mobile and goto:

Add new comment

The content of this field is kept private and will not be shown publicly.
  • No HTML tags allowed.
  o8o              oooo           .oooooo.         .oooooo.                 
`"' `888 d8P' `Y8b d8P' `Y8b
oooo .oooo. 888 oooo 888 888 888 ooo. .oo.
`888 `P )88b 888 .8P' 888 888 888 `888P"Y88b
888 .oP"888 888888. 888 888 888 ooooo 888 888
888 d8( 888 888 `88b. `88b d88b `88. .88' 888 888
o888o `Y888""8o o888o o888o `Y8bood8P'Ybd' `Y8bood8P' o888o o888o

Enter the code depicted in ASCII art style.