diff --git a/layouts/partials/section_pager.html b/layouts/partials/section_pager.html
index a3cc8d0a..3f082d6f 100644
--- a/layouts/partials/section_pager.html
+++ b/layouts/partials/section_pager.html
@@ -1,14 +1,18 @@
+{{ $str := "" }}
{{if .NextInSection}}
+ {{/* For the docs layout, prev/next labels are reversed. */}}
+ {{ if eq .Type "docs" }}{{ $str = "previous" }}{{else}}{{ $str = "next" }}{{end}}
{{end}}
{{if .PrevInSection}}
+ {{ if eq .Type "docs" }}{{ $str = "next" }}{{else}}{{ $str = "previous" }}{{end}}
{{end}}