ByExpiryDate
Returns the given page collection sorted by expiration date in ascending order.
Syntax
PAGES.ByExpiryDate
Returns
page.Pages
When sorting by expiration date, the value is determined by your project configuration, defaulting to the expiryDate field in front matter.
{{ range .Pages.ByExpiryDate }}
<h2><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></h2>
{{ end }}To sort in descending order:
{{ range .Pages.ByExpiryDate.Reverse }}
<h2><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></h2>
{{ end }}Last updated:
February 25, 2026
:
Merge commit '0c2fa2460f485e0eca564dcccf36d34538374922' (b0d3364f1)
Improve this page