When you create a Plain Text field it asks if you want to allow line breaks, but they are ignored when output in the template.

I don't want to have to use a rich text field just to enable editors to add a simple line break, but is that my only option?


1 Answer 1


You can still use plain text, you just need to use a filter after

{{ entry.text | nl2br  }}
  • I thought it should be possible but a Google and stackexchange search found nothing.
    – Paul Frost
    Jan 30, 2018 at 22:29
  • Usually just {{entry.text | nl2br }} will work - no need for the raw Jan 31, 2018 at 2:53
  • I have other stuff in there as well to fix the long term issue of nbsp being added in redactor fields, {{ entry.mapDetails | replace({' ' : ' '}) | nl2br | raw }}, do I still need the raw?
    – Paul Frost
    Jan 31, 2018 at 9:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.