diff --git a/doc/source/middleware.rst b/doc/source/middleware.rst
index b54bf8decb..2c9ea5bde7 100644
--- a/doc/source/middleware.rst
+++ b/doc/source/middleware.rst
@@ -4,133 +4,10 @@
 Middleware
 **********
 
-.. _common_tempauth:
+Account Quotas
+==============
 
-TempAuth
-========
-
-.. automodule:: swift.common.middleware.tempauth
-    :members:
-    :show-inheritance:
-
-KeystoneAuth
-============
-
-.. automodule:: swift.common.middleware.keystoneauth
-    :members:
-    :show-inheritance:
-
-.. _healthcheck:
-
-Healthcheck
-===========
-
-.. automodule:: swift.common.middleware.healthcheck
-    :members:
-    :show-inheritance:
-
-.. _recon:
-
-Recon
-===========
-
-.. automodule:: swift.common.middleware.recon
-    :members:
-    :show-inheritance:
-
-.. _memecached:
-
-Ratelimit
-=========
-
-.. automodule:: swift.common.middleware.ratelimit
-    :members:
-    :show-inheritance:
-
-.. _staticweb:
-
-StaticWeb
-=========
-
-.. automodule:: swift.common.middleware.staticweb
-    :members:
-    :show-inheritance:
-
-.. _tempurl:
-
-TempURL
-=======
-
-.. automodule:: swift.common.middleware.tempurl
-    :members:
-    :show-inheritance:
-
-.. _formpost:
-
-FormPost
-========
-
-.. automodule:: swift.common.middleware.formpost
-    :members:
-    :show-inheritance:
-
-Domain Remap
-============
-
-.. automodule:: swift.common.middleware.domain_remap
-    :members:
-    :show-inheritance:
-
-CNAME Lookup
-============
-
-.. automodule:: swift.common.middleware.cname_lookup
-    :members:
-    :show-inheritance:
-
-Cross Domain Policies
-=====================
-
-.. automodule:: swift.common.middleware.crossdomain
-    :members:
-    :show-inheritance:
-
-Name Check (Forbidden Character Filter)
-=======================================
-
-.. automodule:: swift.common.middleware.name_check
-    :members:
-    :show-inheritance:
-
-Memcache
-========
-
-.. automodule:: swift.common.middleware.memcache
-    :members:
-    :show-inheritance:
-
-Proxy Logging
-=============
-
-.. automodule:: swift.common.middleware.proxy_logging
-    :members:
-    :show-inheritance:
-
-.. _catch_errors:
-
-CatchErrors
-=============
-
-.. automodule:: swift.common.middleware.catch_errors
-    :members:
-    :show-inheritance:
-
-.. _gatekeeper:
-
-GateKeeper
-=============
-
-.. automodule:: swift.common.middleware.gatekeeper
+.. automodule:: swift.common.middleware.account_quotas
     :members:
     :show-inheritance:
 
@@ -143,6 +20,22 @@ Bulk Operations (Delete and Archive Auto Extraction)
     :members:
     :show-inheritance:
 
+.. _catch_errors:
+
+CatchErrors
+=============
+
+.. automodule:: swift.common.middleware.catch_errors
+    :members:
+    :show-inheritance:
+
+CNAME Lookup
+============
+
+.. automodule:: swift.common.middleware.cname_lookup
+    :members:
+    :show-inheritance:
+
 .. _container-quotas:
 
 Container Quotas
@@ -152,36 +45,6 @@ Container Quotas
     :members:
     :show-inheritance:
 
-Account Quotas
-==============
-
-.. automodule:: swift.common.middleware.account_quotas
-    :members:
-    :show-inheritance:
-
-.. _slo-doc:
-
-Static Large Objects
-====================
-
-.. automodule:: swift.common.middleware.slo
-    :members:
-    :show-inheritance:
-
-Dynamic Large Objects
-=====================
-
-.. automodule:: swift.common.middleware.dlo
-    :members:
-    :show-inheritance:
-
-List Endpoints
-==============
-
-.. automodule:: swift.common.middleware.list_endpoints
-    :members:
-    :show-inheritance:
-
 .. _container-sync:
 
 Container Sync Middleware
@@ -191,6 +54,13 @@ Container Sync Middleware
     :members:
     :show-inheritance:
 
+Cross Domain Policies
+=====================
+
+.. automodule:: swift.common.middleware.crossdomain
+    :members:
+    :show-inheritance:
+
 .. _discoverability:
 
 Discoverability
@@ -211,3 +81,131 @@ retrieve it, one must use an HMAC-signed request, similar to TempURL.
 The signature may be produced like so::
 
     swift-temp-url GET 3600 /info secret 2>/dev/null | sed s/temp_url/swiftinfo/g
+
+Domain Remap
+============
+
+.. automodule:: swift.common.middleware.domain_remap
+    :members:
+    :show-inheritance:
+
+Dynamic Large Objects
+=====================
+
+.. automodule:: swift.common.middleware.dlo
+    :members:
+    :show-inheritance:
+
+.. _formpost:
+
+FormPost
+========
+
+.. automodule:: swift.common.middleware.formpost
+    :members:
+    :show-inheritance:
+
+.. _gatekeeper:
+
+GateKeeper
+=============
+
+.. automodule:: swift.common.middleware.gatekeeper
+    :members:
+    :show-inheritance:
+
+.. _healthcheck:
+
+Healthcheck
+===========
+
+.. automodule:: swift.common.middleware.healthcheck
+    :members:
+    :show-inheritance:
+
+KeystoneAuth
+============
+
+.. automodule:: swift.common.middleware.keystoneauth
+    :members:
+    :show-inheritance:
+
+List Endpoints
+==============
+
+.. automodule:: swift.common.middleware.list_endpoints
+    :members:
+    :show-inheritance:
+
+Memcache
+========
+
+.. automodule:: swift.common.middleware.memcache
+    :members:
+    :show-inheritance:
+
+Name Check (Forbidden Character Filter)
+=======================================
+
+.. automodule:: swift.common.middleware.name_check
+    :members:
+    :show-inheritance:
+
+Proxy Logging
+=============
+
+.. automodule:: swift.common.middleware.proxy_logging
+    :members:
+    :show-inheritance:
+
+Ratelimit
+=========
+
+.. automodule:: swift.common.middleware.ratelimit
+    :members:
+    :show-inheritance:
+
+.. _recon:
+
+Recon
+===========
+
+.. automodule:: swift.common.middleware.recon
+    :members:
+    :show-inheritance:
+
+.. _slo-doc:
+
+Static Large Objects
+====================
+
+.. automodule:: swift.common.middleware.slo
+    :members:
+    :show-inheritance:
+
+.. _staticweb:
+
+StaticWeb
+=========
+
+.. automodule:: swift.common.middleware.staticweb
+    :members:
+    :show-inheritance:
+
+.. _common_tempauth:
+
+TempAuth
+========
+
+.. automodule:: swift.common.middleware.tempauth
+    :members:
+    :show-inheritance:
+
+.. _tempurl:
+
+TempURL
+=======
+
+.. automodule:: swift.common.middleware.tempurl
+    :members:
+    :show-inheritance: