Purchasely
2.8
2.8
  • Welcome page
  • General
    • Presentation
  • Quick test
    • Test in 5 minutes
  • Basic configuration
    • Console Configuration
      • Creating a new application
      • Creating your Products
        • App Store
        • Play Store
        • Huawei App Gallery
        • Amazon App Store
        • Products & Plans
      • Design your Paywalls
    • SDK installation
      • iOS SDK
      • Android SDK
      • React Native SDK
      • Cordova SDK
    • SDK configuration
    • Webhook
      • Receiving and understanding messages
      • Managing entitlements
      • Subscription events
      • Events attributes
      • Detailed sequence diagrams
    • Observer mode
  • Dashboards
    • Introduction
    • Live
    • Subscriptions
    • Cohorts
    • Trials
    • Events
  • S2S notifications
    • Server-to-server notifications ?
    • App Store
    • Play Store
    • Huawei App Gallery
    • Amazon App Store
  • Integrations
    • Airship
    • Amplitude
    • Braze
    • Firebase
  • Advanced Features
    • Anonymous user
    • Associating content
    • Customising UI
      • Errors & alerts
      • Controllers (iOS) / Fragments (Android)
    • Deeplinks automations
    • Displaying users subscriptions
    • UI Analytics
    • Localization
    • Non-subscription products
    • Promoting your products
      • Self-promotion
      • Promoting In-App Purchases
    • Purchase interceptor
    • Purchase manually
    • Subscription status
    • Paywall Guidelines
  • Others
    • Frequently Asked Questions
    • Migration guides
      • Migrate to Purchasely
      • SDK
        • v2.1.3
        • v2.2.0
      • Webhooks
        • v3.0
  • TESTING
    • Testing Cycle Durations
Powered by GitBook

© Purchasely 2020-2023

On this page
  • Manually set the language
  • Override default localizations

Was this helpful?

  1. Advanced Features

Localization

The SDK displays some text directly to the user (error messages, restore or login button text, …). These texts are translated in 17 languages:

  • English

  • French

  • German

  • Spanish

  • Portuguese

  • Italian

  • Czech

  • Polish

  • Greek

  • Chinese (Simplifed and traditional)

  • Japanese

  • Russian

  • Turkish

  • Swedish

  • Korean

  • Indonesian

That means that every error message and UI element will automatically translated in the user device language (if matching).

Manually set the language

By default, Purchasely uses the device / app language set by the OS. If your app has an internal language selector, you will want to set that language to your Paywalls. You can force the SDK to be working in a specific language by calling the following method.

// Force language in french
let locale = Locale(identifier: "fr")
Purchasely.setLanguage(from: locale)
// Force language in french
NSLocale *locale = [NSLocale localeWithLocaleIdentifier: @"es"];
[Purchasely setLanguageFrom: locale];
// Force language to spanish
Purchasely.language = Locale("es")

// Force language to italian
Purchasely.language = Locale.ITALY
// Force language to spanish
Purchasely.setLanguage(new Locale("es"));

// Force language to italian
Purchasely.setLanguage(Locale.ITALY);
// Force language to spanish
Purchasely.setLanguage("es");
// Force language to spanish
Purchasely.setLanguage("es");

If your paywall is not available in the language you have set, Purchasely will display text inside the paywall in the language of the paywall set in Purchasely console and not the language you have enforced for consistency.

Override default localizations

If you want to change the tone of the messages, you can override our translations and set yours. To do so, you just need to set the key and value corresponding to the message you want to change in your own Localizable.strings file (iOS) or strings.xml (Android) file.

The keys that can be overrided are in the following file with the default translations in English.

PreviousUI AnalyticsNextNon-subscription products

Last updated 3 years ago

Was this helpful?

Your language code must be or .

ISO 639-1
ISO 639-2
7KB
Localizable.strings
iOS Localizable.strings - English version