I started making another project with django and again i had a hard time remembering how configure static media serving.
Here are the important steps to make it work.


  1. Get a webserver running and make it serve your static files, lets say under http://localhost/project_media

  2. Open s_ettings.py_ of your project and insert the following lines:

  3. Edit the line: MEDIA_URL = and point it to http://localhost/project_media

  4. Edit the view where you want to make use of the static files and use the following code:
    from django.shortcuts import render_to_response
    from django.template import RequestContext
    def index(request):
    return render_to_response(‚page.html‘, {},

  5. No open the page.hmtl and access the media url with the template tag: __


Thats it. Not much to it, but the documentation lacks a place where all that information is tied
together, or i was just to blind to see it.