Want to expose your localhost to the internet?
Want to preview your React.js or Next.js website on any device, especially on mobile, to see how it looks?
Follow these simple steps using Cloudflare Tunnel 👇
1. Open Command Prompt / Terminal
2. Install cloudflared:
🔹 On macOS:
brew install cloudflared
🔹 On Windows:
winget install --id Cloudflare.cloudflared
3. Run the tunnel command:
🔸 For Vite (React.js):
cloudflared tunnel --url http://localhost:5173
🔸 For Next.js:
cloudflared tunnel --url http://localhost:3000
🌐 This will give you a public URL that you can open on your phone or share with others.
📸 Check the attached image for a visual walkthrough!
Almost nine months ago, a client reached out to me. He said that I had built a lot of micro SaaS websites using AI (ChatGPT).
And after seeing his work, I was like, "Whaaat???"
I asked him, "Really???" and he said, "Yes."
He also mentioned that he had no coding experience and wanted me to fix bugs and do some improvements.
Later, I rejected the offer because the budget was too low.