DoesNotExist at /admin/login/
Question: 
      DoesNotExist at /admin/login/
    
    Site matching query does not exist.
    
    Request Method:     GET
    Request URL:    https://tehb123.pythonanywhere.com/admin/login/?next=/admin/
    Django Version:     1.9.3
    Exception Type:     DoesNotExist
    Exception Value:    
    
    Site matching query does not exist.
    
    Exception Location:     /usr/local/lib/python3.5/dist-packages/django/db/models/query.py in get, line 387
    Python Executable:  /usr/local/bin/uwsgi
    Python Version:     3.5.1
    Python Path:    
    
    ['/var/www',
     '.',
     '',
     '/home/tehb123/.local/lib/python3.5/site-packages',
     '/var/www',
     '/usr/lib/python3.5',
     '/usr/lib/python3.5/plat-x86_64-linux-gnu',
     '/usr/lib/python3.5/lib-dynload',
     '/usr/local/lib/python3.5/dist-packages',
     '/usr/lib/python3/dist-packages',
     '/home/tehb123/mysite']
    
    Server time:    Thu, 13 Oct 2016 05:34:55 +0000
    

  * urls

from django.conf.urls import url, patterns, include from django.contrib import
admin from django.contrib.flatpages import views

urlpatterns = [ url(r'^admin/', admin.site.urls), url(r'^',
include('Mysitez.urls')), # url(r'^pages/',
include('django.contrib.flatpages.urls')), ]

urlpatterns += [ url(r'^(?P.*/)$', views.flatpage), ]

  * settings

INSTALLED_APPS = [ 'django.contrib.admin', 'django.contrib.auth',
'django.contrib.contenttypes', 'django.contrib.sessions',
'django.contrib.messages', 'django.contrib.staticfiles',
'django.templatetags', 'django.apps', 'django.contrib.sites',
'django.contrib.flatpages', 'Mysitez',

]


Answer: # The admin site

once you create the project with django version > 1.6 , the admin site will
enable django itself. but make sure you have following
["<https://docs.djangoproject.com/en/1.10/ref/contrib/admin/>"], once you
create project , make `python manage.py migrate` then create the admin user
using (`python manage.py createsuperuser` ). do the run command see the url
like ("<http://127.0.0.1:8000/admin/>") you can see the login page

