diff --git a/rest_framework/templates/rest_framework/docs/document-incl.html b/rest_framework/templates/rest_framework/docs/document-incl.html
new file mode 100644
index 000000000..bb2020364
--- /dev/null
+++ b/rest_framework/templates/rest_framework/docs/document-incl.html
@@ -0,0 +1,17 @@
+{% load rest_framework %}
+
+{% for link_key, link in section.links|items %}
+ {% with section_key=parent_key %}
+ {% include "rest_framework/docs/link.html" %}
+ {% endwith %}
+{% endfor %}
+
+{% for section_key, sect in section.data|items %}
+ {% if section_key %}
+
{{ parent_key|add:' / ' }}{{ section_key }}
+ {% endif %}
+
+ {% with parent_key=parent_key|add:'-'|add:section_key section=sect %}
+ {% include "rest_framework/docs/document-incl.html" %}
+ {% endwith %}
+{% endfor %}
diff --git a/rest_framework/templates/rest_framework/docs/document.html b/rest_framework/templates/rest_framework/docs/document.html
index ef5f5966b..16a487d71 100644
--- a/rest_framework/templates/rest_framework/docs/document.html
+++ b/rest_framework/templates/rest_framework/docs/document.html
@@ -14,17 +14,6 @@
-{% for section_key, section in document.data|items %}
-{% if section_key %}
- {{ section_key }}
-
-{% endif %}
-
- {% for link_key, link in section.links|items %}
- {% include "rest_framework/docs/link.html" %}
- {% endfor %}
-{% endfor %}
-
-{% for link_key, link in document.links|items %}
- {% include "rest_framework/docs/link.html" %}
-{% endfor %}
+{% with parent_key=None section=document %}
+ {% include "rest_framework/docs/document-incl.html" %}
+{% endwith %}
diff --git a/rest_framework/templates/rest_framework/docs/sidebar-menu.html b/rest_framework/templates/rest_framework/docs/sidebar-menu.html
new file mode 100644
index 000000000..f4d92705c
--- /dev/null
+++ b/rest_framework/templates/rest_framework/docs/sidebar-menu.html
@@ -0,0 +1,18 @@
+{% load rest_framework %}
+
+{% if section.links %}
+
+{% endif %}
+
+{% for key, sect in section.data|items %}
+
+ {{ parent_key|add:' / ' }}{% if key %}{{ key }}{% else %}API Endpoints{% endif %}
+
+ {% with section=sect parent_key=parent_key|add:'-'|add:key %}
+ {% include 'rest_framework/docs/sidebar-menu.html' %}
+ {% endwith %}
+{% endfor %}
diff --git a/rest_framework/templates/rest_framework/docs/sidebar.html b/rest_framework/templates/rest_framework/docs/sidebar.html
index c6ac26f66..3643983dd 100644
--- a/rest_framework/templates/rest_framework/docs/sidebar.html
+++ b/rest_framework/templates/rest_framework/docs/sidebar.html
@@ -1,20 +1,12 @@
-{% load rest_framework %}