命令行安装django-bootstrap3库

pip install django-bootstrap3

配置文件settings.py设置

INSTALLED_APPS = [
	...
	# 第三方应用程序
    'bootstrap3'
]
### 安装jquery文件
BOOTSTRAP3 = {
    'include_jquery':True,
}

网页中加载bootstrap3的js,css文件

{% load bootstrap3 %}
<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Bootstrap Learning</title>
    {% bootstrap_css %}
    {% bootstrap_javascript %}
</head>
<body>
	<div class="page-header">
		<h1>
			Example page header 
			<small>Subtext for header</small>
		</h1>
	</div>
</body>
</html>