Managing Multilingual Content

Building applications for a global audience means delivering content in multiple languages. This often introduces significant complexity: managing different versions of content, handling missing translations, and ensuring a seamless user experience across regions.

FoxNose's localization system is designed to solve these problems directly. It provides a robust, built-in solution for managing multilingual content, allowing you to focus on your application's logic instead of building a localization system from scratch.


Primary Language

Every FoxNose environment requires at least one locale, which serves as your project's primary language. This ensures a consistent base for all your content.

  • By default, this is set to English (en), but you can change it to any supported language at any time via the dashboard.
  • If your application only needs a single language, no further locale setup is required. FoxNose handles all content in this primary language.
  • Important: Changing the primary language does not automatically re-translate or convert existing content. It only sets the new default for future operations.

As your global reach expands, you can easily add more locales, provided you stay within your plan's locale quota.

Handling Missing Translations

One of the biggest challenges in multilingual applications is dealing with content that hasn't been translated yet. FoxNose provides a flexible fallback system to ensure your users always see content, even if a specific translation is missing.

  • Explicit Translation (Default): By default, Flux API only returns the translations actually stored on a resource. If a translation for a requested locale is missing, the field will appear as null. This is ideal for development and QA environments, as it clearly highlights content gaps that need to be addressed.
  • Automatic Fallback: For production environments, you can enable fallback_locales=true in your Flux API requests (get_one, get_many, or _search). When enabled, if a translation for a requested locale is missing, Flux automatically fills that field with the value from your project's primary language. This ensures a seamless user experience, preventing empty fields from appearing in your application.

This dual strategy allows you to mix and match: use the explicit null behavior in staging to pinpoint missing translations, and enable automatic fallback in production to guarantee a complete content delivery.

Adding and Deleting Languages

FoxNose makes it straightforward to grow your application's linguistic capabilities, allowing you to add and remove locales as your needs evolve.

Adding a New Locale

Adding a new language to your project is a seamless process:

  • Immediate Availability: Once added (and subject to your plan's locale quota), the new locale becomes instantly accessible via both the Management API and Flux API.
  • Gradual Translation: You don't need to translate all your content at once. FoxNose supports progressive translation; as soon as a translation for a specific field is saved, it becomes available for that locale. This allows for flexible and iterative translation workflows.

Deleting a Locale

Deleting a locale effectively removes it from your active language list, but with careful data handling:

  • Removed from APIs: The locale will no longer appear in locale lists, and Flux will stop returning content for it.
  • Data Retention for Recovery: Importantly, existing localized values for that locale are retained internally within your resources. If you later decide to re-create a locale with the same code, FoxNose intelligently reuses these previous translations, preventing accidental data loss.
  • Permanent Data Removal: To permanently remove all localized values for a deleted locale from your resources, you must explicitly edit the affected resources (via the dashboard or Management API) and remove the translations from the relevant fields.

Next Step: Combining with Semantic Search

Now that you understand the basics of localization, learn how to combine it with FoxNose's powerful semantic search to build truly intelligent, multilingual applications.

Was this page helpful?