These are the options you see when you run ‘npm start’ or ‘expo start’, you see a bar code under the options for Tunnel, Lan, Local.
After selecting an option, then scanning the bar code (QR), how come some of them work sometimes vs. others? Often times if I switch to Tunnel, my project actually loads on my Expo app on my Android device. I always am connected to the same IP address on my phone and laptop.
local: this points to your own computer, 127.0.0.1 / localhost
lan: this is your network ip address
tunnel: this uses ngrok to make the server available anywhere on the internet if they have access to the url, so you could share the project with someone outside of your local network or access it from your phone if you are not on the same network or your network policies restrict access to other devices on the network
you might not be on the same network, or you are on a network that doesn’t let you connect to other devices on the network. you can also plug in your phone to your computer, use localhost, then press “a” in the expo-cli interactive prompt (or press open on android in the web browser) and it will run a tool called adb reverse which tells your android device to proxy requests to localhost to your computer via usb