Django Framework- page not found
Question: Why am i getting a 404 in this?

This is my mysite/urls.py file:

    
    
    from django.conf.urls import url, include
    from django.contrib import admin
    
    urlpatterns = [
    url(r'^admin/', admin.site.urls),
    url(r'^$/', include('personal.urls')),
    ]
    

And this is my mysite/personal/urls.py file

    
    
    from django.conf.urls import url
    from . import views
    urlpatterns =[url(r'^$',views.index, name='index')]
    

The mysite/personal/views.py

    
    
    from django.shortcuts import render
    
    def index(request):
        return render(request, 'personal/home.html')
    

after that i have created the templates folder like
templates/personal/header.html. The file looks like this

    
    
    <body class="body" style="background-color:#f6f6f6">
    <div>
       {% block content %}
       {% endblock %}   
    </div>
    </body>   
    

Now about the home.html in the same folder

    
    
    {% extends "personal/header.html" %}
    {% block content %}
    <p>Hey! Welcome to my website! Well, I wasn't expecting guests. Um, my name is HVS. I am a programmer.</p>
    {% endblock %}
    

I HAVE ALSO INSTALLED THE APP IN settings.py file in mysite sub directory but
still when i run the

    
    
    ">python manage.py runserver"
    

it runs OK bt the page tells me that the url not found 404!!

This is my browser output:

[![Screenshot](http://i.stack.imgur.com/P7HIK.png)](http://i.stack.imgur.com/P7HIK.png)

I am using Windows 8, python 3 & django 1.9


Answer: According to django
[docs](https://docs.djangoproject.com/en/1.9/intro/tutorial01/):

> The include() function allows referencing other URLconfs. Note that the
> regular expressions for the include() function doesn’t have a $ (end-of-
> string match character) but rather a trailing slash

So you should change it to this:

    
    
    url(r'^/', include('personal.urls'))
    

