Localizing Object Definitions and Entries
Liferay DXP 2023.Q3+/Portal GA92+
Liferay objects are integrated with the localization framework, so you can add translations for definition labels, and users can enter localized values for most fields. With localized objects you can better serve your global users.
Localizing Object Definition Labels
When configuring an object definition, you can localize the definition’s labels, as well as labels for its fields, relationships, actions, and view columns. This determines how these elements appear in object layouts and views.
Additionally, you can localize validation error messages.
Localizing Object Entry Fields
In addition to localizing definition labels, you can enable translation support for most custom fields.
From Liferay DXP 2023.Q3-2025.Q1 (Portal GA92-GA132), only text fields (Text, Rich Text, and Long Text field types) were localizable.
For these numeric, selection, and text field types you can provide locale-specific values (e.g., translations):
- Integer
- Long Integer
- Decimal
- Precision Decimal
- Boolean
- Picklist
- Multi-select Picklist
- Text
- Long Text
- Rich Text
For Date and Date Time fields, you can provide locale-specific values; locale-specific formatting is provided automatically by Java’s DateFormat
API.
To configure fields so that entry creators can localize their input,
-
Open the Objects application and begin editing the desired definition.
-
Before Liferay DXP 2025.Q2/Portal GA136, you must toggle Enable Entry Translation in the Details tab.
For Liferay DXP 2025.Q2+/Portal GA136+, all localization configuration is in the field configuration.
-
Add a new field. If the field type is localizable, you can enable it in the New Field dialog:
-
Click Save.
- Before Liferay DXP 2025.Q2/Portal GA136, localized fields could not be mandatory.
- When using localization, field validations, conditions, filters, and sorting only support the default language.
While enabled, you can use the language selector button to localize the field’s value when creating entries.