Search code examples
pythondjangongrok

Ngrok "HTTP Error 404". The requested resource is not found


Error picture

I've tried to execute my django-app with "ngrok". Added url to "ALLOWED_HOSTS" and other variables which need that. I did 'py manage.py runserver' and 'ngrok http 80' together => no result.


Solution

  • A few hours later, I figure out that you must run your ngrok from CMD, not from IDE Terminal.

    P.S. If you set domain in 'C:\Windows\System32\Drivers\etc\ hosts' for your local address, that command help may help you:

    ngrok http --host-header=rewrite mysite.com:80

    where mysite.com - your domain name, :80 - your port.