skip to navigation
skip to content

django-bower 5.0

Integrate django with bower

Latest Version: 5.2.0

Easy way to use bower with your django project.

Bower is a package manager for the web. It offers a generic, unopinionated solution to the problem of front-end package management, while exposing the package dependency model via an API that can be consumed by a more opinionated build stack. There are no system wide dependencies, no dependencies are shared between different apps, and the dependency tree is flat.

Read full documentation on read-the-docs.


Install django-bower package:

pip install django-bower

Add django-bower to INSTALLED_APPS in your settings:


Add staticfinder to STATICFILES_FINDERS:


Specifie path to components root (you need to use absolute path):


If you need, you can manually set path to bower

BOWER_PATH = '/usr/bin/bower'

You can see example settings file in example project.


Specifie BOWER_INSTALLED_APPS in settings, like:


Download bower packages with management command:

./ bower install

Add scripts in template, like:

{% load static %}
<script type="text/javascript" src='{% static 'jquery/jquery.js' %}'></script>

In production you need to call bower install before collectstatic:

./ bower install
./ collectstatic

If you need to pass arguments to bower, like –allow-root, use:

./ bower install -- --allow-root

You can use bower freeze to receive BOWER_INSTALLED_APPS with fixed current versions:

./ bower freeze

You can call bower commands like info and update with:

./ bower info backbone
./ bower update

Python 3 support

django-bower supports python 3.3+

File Type Py Version Uploaded on Size
django-bower-5.0.tar.gz (md5) Source 2014-04-10 6KB