Run your React Next Js localhost code on a mobile device and test mobile responsive Live

Monib Bormon
2 min readSep 25, 2023

--

Hello Programmers, In today's blog I will share how you can run your projects like React Js, Next Js, or index.html on mobile and check the responsiveness of mobile screens quickly.

I will share two examples here with Next js application and normal index.html with live server.

So let’s jump into our first Example,

First of all, you have to open your terminal from PC and type ipconfig like the photo

And here you can see IPv4 Address : 192.168.1.102 . All you have to do is get the IPv4 address.

Then run your Next Js Application on your PC locally. After that open any of your mobile browsers like Chrome. In the address bar type the IPv4 address like this http://192.168.1.102:3000 . And boom you are done. Now you will get updates of your code changes instantly.

Here is the second example, if you want to run an index.html file on your phone then run this file on your code editor with Live Server. Then open Your phone and like the first one open any browser and type this url http://192.168.1.102:5500/index.html. You are Live now.

Like the above examples, you can run any of your static codes on a mobile device and check the actual mobile responsiveness.

Happy Learning. Cheers 🤟🤟

--

--

Monib Bormon
Monib Bormon

Responses (1)