{% localize %} Tag

turns localized formatting on or off for a block.

Formatting As Markdown

Argument(s)
on|off
Closing tag
Required — {% endlocalize %}
Requires
{% load l10n %}

Documentation

Turns locale-aware formatting on or off for everything inside it, rather than one value at a time.

Template

{% load l10n %}
{% localize off %}
  {{ value }}
{% endlocalize %}

off is the one people want: a number headed for JavaScript, a CSV, or an HTML attribute has to stay machine-readable, and a comma decimal separator quietly breaks all three.


Did we get something wrong? Is there a use case for the localize tag that we should add? Please let us know.

Send Feedback

Official Documentation
This page last updated on August 20, 2026