Answer the question
In order to leave comments, you need to log in
Why is the 404 page not showing (Django)?
At the root of the project in the templates folder is the 404.html file. In settings.py DEBUG= False. When you navigate to a known unknown URL, a page is displayed that looks like:
--------------------------------
Not Found
The requested URL /test_404 was not found on this server.
-----------------------
If DEBUG = True, then Page Not Found (404)...
Answer the question
In order to leave comments, you need to log in
Because in urls.py you need to write something like handler404 = 'mysite.views.my_custom_page_not_found_view' and then only do Debug=false
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question