gohugoio/hugo · error
pagination not supported for this page
Error message
pagination not supported for this page
What it means
Returned by the paginatorNotSupported stub installed at page__output.go:27-29 whenever a pageOutput is created for a non-branch page (render=false or the page is not a branch bundle). Only branch pages — home, section, taxonomy, term — get a real pagePaginator; everything else gets this stub, so calling .Paginate / .Paginator on it fails.
Solutions
- Move the .Paginate call into a branch-page template (list.html / section / home / taxonomy).
- Guard the call: only invoke `.Paginate` when `.IsSection` or `eq .Kind "section"` (or the relevant branch kind).
- Ensure the page is a branch bundle (_index.md) rather than a leaf bundle (index.md) if it should paginate children.
Example fix
{{/* before: called on every page, including regular pages */}}
{{ $pages := .Paginate .Pages }}
{{/* after: only branch pages */}}
{{ if .IsSection }}
{{ $pages := .Paginate .Pages }}
{{ end }} Defensive patterns
Strategy: type-guard
Type guard
{{/* Only call .Paginate on branch pages */}}
{{- define "maybe-paginate" -}}
{{- if or (eq .Kind "home") (eq .Kind "section") (eq .Kind "taxonomy") (eq .Kind "term") -}}
{{- .Paginate .Pages -}}
{{- end -}}
{{- end -}} Prevention
- Centralize pagination in a partial that checks `.IsSection`/Kind before calling .Paginate.
- Reserve list.html / section layouts for branch bundles (_index.md).
- Never call .Paginate inside single-page or shortcode templates.
When it happens
Trigger: A template calls `.Paginate` (or accesses `.Paginator`) on a regular/leaf page, a 404 page, or any output that was not marked for rendering; using a list partial on a single page; calling Paginate inside a shortcode rendered on a leaf bundle.
Common situations: Reusing a list-section layout on a single page; headless/standalone output formats; calling Paginate in a baseof or header partial included by a regular page.
Related errors
- 'pager size' must be a positive integer
- 'paginate' configuration setting must be positive to…
- too many arguments, 'pager size' is currently the only…
- alignx must be one of left, center, right
- can't apply the operator to the values
AI-assisted analysis of gohugoio/hugo@52c9bd7908 (2026-08-09).
Data as JSON: /api/errors/887557f00187e549.
Report an issue: GitHub.
Appendix: source
Thrown at hugolib/page__output.go:28
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
package hugolib
import (
"fmt"
"path"
"strings"
"github.com/gohugoio/hugo/identity"
"github.com/gohugoio/hugo/output"
"github.com/gohugoio/hugo/resources/page"
"github.com/gohugoio/hugo/resources/resource"
)
var paginatorNotSupported = page.PaginatorNotSupportedFunc(func() error {
return fmt.Errorf("pagination not supported for this page")
})
func newPageOutput(
ps *pageState,
pp pagePaths,
f output.Format,
render bool,
) *pageOutput {
var targetPathsProvider targetPathsHolder
var linksProvider resource.ResourceLinksProvider
ft, found := pp.targetPaths[f.Name]
if !found {
// Link to the main output format
ft = pp.targetPaths[pp.firstOutputFormat.Format.Name]
}
targetPathsProvider = ft
linksProvider = ftView on GitHub (pinned to 52c9bd7908)