Localization

Translate and adapt an app's text, resources and formatting for many languages and regions.

Introduced
2001
Mac OS X 10.0
Kind
Platform feature
Runs on
Get it from
iOS
2.0+
iPadOS
2.0+
Mac Catalyst
13.0+
macOS
10.0+
tvOS
9.0+
visionOS
1.0+
watchOS
2.0+

Overview

Localization adapts an app for people who speak different languages and download it from different App Store territories. Apps use localizable APIs such as String(localized:) and SwiftUI's Text, and Foundation formats dates, numbers and currencies for each locale. Xcode finds user-facing strings at build time and keeps them in String Catalogs, where you can add languages, handle plurals and vary text by device.

You can also export localizations as XLIFF-based files for translators and import their work back. Xcode 26 can generate translator comments with an on-device model. In Xcode 27, coding agents can add languages and translate String Catalogs for you.

String Catalogs

Manage every string, plural and device variant in one .xcstrings file.

Grammar agreement

Foundation inflects words to agree with counts in supported languages.

Export and import

Send XLIFF-based localization files to translators and import the results.

Agent translation

In Xcode 27, coding agents add languages and translate String Catalogs.

CartHeader.swift
import SwiftUI struct CartHeader: View { let itemCount: Int var body: some View { VStack(alignment: .leading) { Text("Your cart", comment: "Title above the items in the cart") Text(AttributedString(localized: "^[\(itemCount) item](inflect: true) ready to ship")) } .navigationTitle(String(localized: "Checkout", comment: "Checkout screen title")) } }

History

How it grew up.

2001

NSLocalizedString

Mac OS X 10.0 ships with the NSLocalizedString macro for localized string lookup.

2019

Per-app language

iOS 13 lets people choose an app's language separately from the system language.

2021

Grammar agreement

iOS 15 and macOS Monterey add String(localized:) and automatic grammar agreement.

2023

String Catalogs

Xcode 15 gathers an app's strings into String Catalogs that sync after each build.

2026

Agent translation

Xcode 27 lets coding agents translate String Catalogs using the app's context.