# Smart Localization Lite

Provides a lightweight localization workflow for managing text keys and language tables inside Unity.

{% embed url="<https://assetstore.unity.com/packages/tools/localization/smart-localization-lite-332202>" %}

{% tabs %}
{% tab title="Overview" %}
Smart Localization (Lite) is a lightweight Unity localization system designed specifically for TextMeshPro components. It allows you to define per-language text entries directly on each `LocalizedTMP` component and automatically refresh them when the active language changes.

The Lite version includes:

* Centralized language configuration via Project Settings
* Per-component text entries
* Automatic editor and runtime refresh
* Integrated translation using MyMemory (free public API)
* Daily character quota management

The system is designed for small-to-medium projects that require straightforward string-based localization without external CSV pipelines or addressable databases.

It operates entirely through ScriptableObject settings and runtime event dispatching, ensuring minimal overhead and no runtime reflection cost.

<figure><img src="/files/Gy19HTUpJeGCKFM5fI7y" alt=""><figcaption></figcaption></figure>
{% endtab %}

{% tab title="Installation" %}
After importing the package, open:

**Project Settings → Smart Localization Lite**

This creates two assets automatically:

* A runtime `LocalizationSettingsLite` asset stored in `Resources`
* An editor-only `EditorLocalizationSettingsLite` asset for API settings&#x20;

At runtime, the system initializes automatically using:

* A persisted language stored in `PlayerPrefs`
* The configured default language as fallback

No additional bootstrap scene setup is required.
{% endtab %}

{% tab title="Quick Start" %}

1. Open **Project Settings → Smart Localization Lite**
2. Configure your supported languages (default EN/FR provided)
3. Set the source, default, and current language
4. Add a `LocalizedTMP` component to any GameObject containing a `TMP_Text`
5. Enter text values per language in the Inspector
6. Change the current language in Project Settings or at runtime using:

```csharp
LocalizationServiceLite.CurrentLanguage = "fr";
```

All active `LocalizedTMP` components automatically refresh when the language changes

<figure><img src="/files/TLi01tTmpb3RpEbEQHMw" alt=""><figcaption></figcaption></figure>
{% endtab %}

{% tab title="Workflow" %}
Smart Localization Lite follows a per-component workflow.

Each `LocalizedTMP` component stores language entries internally. When enabled, it ensures that all configured languages exist as slots inside the component.

When the language changes, `LocalizationServiceLite` raises an event. All subscribed components refresh their displayed text accordingly.

Translation in the Lite version is performed per component through the Inspector. When the Translate button is pressed:

* The source language entry is used as input
* All unlocked target languages are translated
* Character quota is validated
* Progress feedback is displayed
* Translations are written directly to entries&#x20;

Quota limits:

* \~5,000 characters/day without email
* \~50,000 characters/day with optional email&#x20;

Quota resets automatically every UTC day.

<figure><img src="/files/1fYDdrpwbU5LafiL0ICH" alt=""><figcaption></figcaption></figure>
{% endtab %}

{% tab title="Technical Notes" %}
Smart Localization Lite is built around three core elements:

1. `LocalizationSettingsLite` (ScriptableObject in Resources)
2. `LocalizationServiceLite` (static runtime manager)
3. `LocalizedTMP` (per-component localized text holder)

Language normalization ensures codes such as `en-US` are reduced to `en` and validated against supported languages.

Language changes are persisted using `PlayerPrefs`, ensuring the selected language survives application restarts.

The translation provider in Lite relies exclusively on the public MyMemory API through `UnityWebRequest`. Requests are asynchronous and support cancellation tokens.

Editor-only data (email and quota tracking) is stored outside the `Resources` folder to avoid embedding personal data in builds.

No runtime HTTP requests occur unless explicitly triggered in the Editor.
{% endtab %}

{% tab title="Limitations" %}
Smart Localization Lite is intentionally minimal.

It does not include:

* Batch project-wide translation
* External file import/export (CSV/JSON)
* Key-based global string tables
* Smart formatting or pluralization rules
* Translation memory caching
* Multiple translation providers
* Cloud or remote configuration

Localization is component-based, not key-based. Text reuse across multiple objects requires manual duplication.

The MyMemory API is public and free; translation quality may vary and rate limits apply.

Only `TMP_Text` components are supported.

<figure><img src="/files/jXdpqZeGroiWExcPZfTQ" alt=""><figcaption></figcaption></figure>
{% endtab %}

{% tab title="FAQ" %}

<details>

<summary>Does this tool run in builds?</summary>

Yes. Runtime localization works in builds. Translation via MyMemory is Editor-only.

</details>

<details>

<summary>Where are language settings stored?</summary>

Runtime language configuration is stored in a ScriptableObject inside `Resources`. The current language is persisted in `PlayerPrefs`

</details>

<details>

<summary>How does the quota system work?</summary>

The Lite version tracks characters translated per day. The limit is automatically set to 5k characters/day, or 50k/day if an email is provided in Project Settings

</details>

<details>

<summary>Can I change language at runtime?</summary>

Yes. Simply assign a supported language code to:

```csharp
LocalizationServiceLite.CurrentLanguage
```

All subscribed components refresh automatically

</details>

<details>

<summary>What happens if a translation fails?</summary>

The system catches per-language exceptions and continues processing remaining targets. Partial completion warnings are displayed in the Editor

</details>

<details>

<summary>Does this modify my TMP components?</summary>

No. It only updates the `text` property at runtime or in edit mode depending on settings.

</details>
{% endtab %}
{% endtabs %}

***

{% content-ref url="/spaces/u6FKPRtV6vGPNteP2vic/pages/QPeZ9xaf3BcqDtVRdMFF" %}
[Smart Localization Lite Changelog](/julestools-docs/changelog/readme-5.md)
{% endcontent-ref %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://julestools.gitbook.io/julestools-docs/documentation/tools/smart-localization-lite.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
