---
title: '{% translate %}'
description: marks a string for translation.
date: '2026-08-21'
categories:
  - Template Tag
  - Utility
canonical: https://www.djangotemplatetagsandfilters.com/tags/translate/
doc_link: >-
  https://docs.djangoproject.com/en/6.1/topics/i18n/translation/#std-templatetag-translate
---

# {% translate %}

marks a string for translation.

## Documentation

Translates a string using the active language.

### Template

```django
{% load i18n %}
<h1>{% translate "Welcome back" %}</h1>
```

The literal is what gets collected by `makemessages` and what a translator sees, so keep it a plain sentence rather than something assembled from pieces. For anything containing a variable or needing a plural, use `{% blocktranslate %}`.
