setting.py
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = Flase
ALLOWED_HOSTS = ['*']
templates/404.html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Title</title>
</head>
<body>
{{request_path}}
</body>
</html>