Search code examples
command-line-interfaceshopifyngrok

502 Bad Gateway using ngrok


I am trying to use ngrok to create a dev shopify app. I had it working for a short time, but now i keep getting the error message.

enter image description here

The connection to https://da003848.ngrok.io was successfully tunneled to your ngrok client, but the client failed to establish a connection to the local address localhost:3000.

I am alo seeing the 502 error below;

Session Status                online                                                                                     
Account                       whileymai (Plan: Free)                                                                     
Version                       2.3.35                                                                                     
Region                        United States (us)                                                                         
Web Interface                 http://127.0.0.1:4040                                                                      
Forwarding                    http://da003848.ngrok.io -> http://localhost:3000                                          
Forwarding                    https://da003848.ngrok.io -> http://localhost:3000                                         

Connections                   ttl     opn     rt1     rt5     p50     p90                                                
                              2       0       0.01    0.00    0.00    0.00                                               

HTTP Requests                                                                                                            
-------------                                                                                                            

GET /favicon.ico               502 Bad Gateway                                                                           
GET /

                      502 Bad Gateway   

Not sure how to fix this. Thanks


Solution

  • when your terminal in on then ngrok will return the same URL but when you restart ngrok it will create a VPN with a new URL. You can also signup then it will work permanently until your system is ON. Click here to create an account and get YOUR_AUTHTOKEN

    $ ngrok authtoken <YOUR_AUTHTOKEN>