Skip to content Skip to footer navigation
You are reading the docs for an old version of Statamic. Consider upgrading to Statamic 6.

Excerpt Modifier

Generate an excerpt from your content.

Breaks a string at a given marker. Uses <!--more--> by default.

---
title: 'Example Entry'
---
Lorem Ipsum dolor sit amet.<!--more--> consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Massa id neque aliquam vestibulum.
{{ books | excerpt }}
{{ Statamic::modify($books)->excerpt() }}
Lorem Ipsum dolor sit amet.

You can override the marker by passing an alternative as the first parameter:

{{ books | excerpt:<!-- end --> }}