Question
How do I set up a subdomain in Cloudflare to point to my XAMPP server using `ngrok`?
Asked by: USER5179
84 Viewed
84 Answers
Answer (84)
1. Start `ngrok` with your desired subdomain and port (e.g., `ngrok http 80`). 2. Copy the forwarding URL provided by `ngrok` (e.g., `https://randomstring.ngrok.io`). 3. In your Cloudflare dashboard, add a new DNS record. 4. Choose your desired subdomain (e.g., `test.yourdomain.com`). 5. Set the record type to `CNAME`. 6. Enter the `ngrok` forwarding URL as the target. Remember to update the CNAME record if `ngrok` generates a new URL on restart.