Localizable Strings Dict

Last updated: July 12, 2023Author: Jakub Pomykała

Localization on macOS and iOS looks the same. Both platforms share the same concepts, programming language and localization approach. In Swift world, the most commonly used localization format for pluralization are *.stringsdict files. Each *.stringsdict file contains translated messages that has plural forms and device variants.

Translations format is based on XML, and it's similar to Android strings.xml format. Each translation file contains a dictionary with keys and values. Each value can be a string or a dictionary with plural forms. Each plural form is a dictionary with a key and a value. The key is a plural form name and the value is a translated message.

Note: Localizable.stringsdict files are used only for pluralization and device variants. For simple translations, use Localizable.strings file format.

File format example

<plist version="1.0">
        <!-- Pluralization -->
        <key>%d home(s) found</key>
                <string>No homes found</string>
                <string>%d home found</string>
                <string>%d homes found</string>

        <!-- Device specific translations -->
                <string>Tap here</string>
                <string>Click here</string>
                <string>Press here</string>

Upload with CLI

simplelocalize upload --apiKey <PROJECT_KEY> \
  --uploadFormat localizable-strings-dict \
  --uploadPath ./{lang}/Localizable.stringsdict

Learn more about SimpleLocalize CLI and translations upload feature.

Download with CLI

simplelocalize download --apiKey <PROJECT_KEY> \
  --downloadFormat localizable-strings-dict \
  --downloadPath ./{lang}/Localizable.stringsdict

Learn more about SimpleLocalize CLI and translations download feature.