How to use ngrok with https://localhost:[port]

Viewed 353

I'm doing a simple exercises on Web App Install Banner on C# / .NET / MVC which requires https. When I try to test it by using ngrok as hosting services, the website loads for a while and then I received a 502 bad gateway error.

I normally run my ngrok with this command ngrok http -host-header="localhost:44315" 44315.

I'm pretty new to all this programming and web stuffs. So please guide me in the right way. Thanks

1 Answers

You can configure ngrok to forward to a local HTTPS server by specifying the https:// scheme.

ngrok http -host-header="localhost:44315" https://localhost:44315

Docs here: https://ngrok.com/docs#http-local-https

Related