Display Strapi relations with clear, customizable labels built from your content fields
released September 10, 2026
npm install strapi-relation-namesClear and customizable relation labels for Strapi v5
Display Strapi relations using readable labels built from your content fields instead of relying on the default relation name.
Ever wanted to display a relation as custom text or with nested field values? This plugin solves exactly that:

Install via npm:
npm install strapi-relation-namesor yarn:
yarn add strapi-relation-namesor pnpm:
pnpm add strapi-relation-namesEnable the plugin:
// config/plugins.{js,ts}
'strapi-relation-names': {
enabled: true,
},After installing and enabling the plugin, open the Strapi Admin settings panel:
Settings → Global → Relation Names
Each relation field is displayed together with the scalar fields available on its related content type or component.
Create a label using placeholders e.g.:
{firstName} {lastName}You can also mix placeholders with static text:
Name: {firstName} {lastName}It is also possible to transform a label's value using pipe syntax: {createdAt | toLocalDateTime}
Currently the following transformations exist:
toLocalDate — formats date values using the configured locale and time zone.toLocalDateTime — formats date-time values using the configured locale and time zone.Possible configuration keys are listed below; omitted keys keep the plugin defaults.
| Key | Description | Possible values |
|---|---|---|
collections | Limit relation names to the listed collection and single type UIDs. Leave empty to include all. | string[] (default: []) |
locale | Locale used by date transformations. | string (default: runtime locale) |
timeZone | IANA timezone used by date transformations. | string (default: runtime timezone) |
Example:
// config/plugins.{js,ts}
'strapi-relation-names': {
enabled: true,
config: {
collections: ['api::article.article', 'api::author.author'],
locale: 'de-AT',
timeZone: 'Europe/Vienna',
},
},At runtime, the server-side plugin decorates Strapi Content Manager relation responses and field metadata. It reads the configured template, validates each placeholder against the related content type schema, and renders the label from the returned relation data. If a value is not present, it performs a permission-aware hydration query; nested component paths are loaded by populating their component root. The rendered label is then exposed through Strapi's normal relation display mechanism. Missing field values are replaced with an empty string.
For example:
{firstName} {lastName}with a missing lastName becomes:
JohnIf the complete rendered label is blank, Strapi automatically falls back to its default relation label.
The default label is also used when:
If you have any feature requests or suggestions, please open a dedicated issue.
If you encounter any issues, please feel free to open an issue on the GitHub repo.
Contributions are welcome! If you have suggestions or improvements, please open an issue or submit a pull request to the dev branch.
Share your work with the community and get it listed in the Strapi ecosystem for everyone to discover and use.
Submit
