# spatie/laravel-translatable

Making Eloquent models translatable

Repository: https://github.com/spatie/laravel-translatable
Canonical: https://ross.abutalabs.com/products/laravel-translatable
Homepage: https://spatie.be/docs/laravel-translatable
Language: PHP
License: MIT
License Family: permissive
Topics: laravel, php, i18n, translated-attributes, eloquent
Last push: 2026-06-26T09:47:50+00:00

## Health v2 (maintenance only)
Score: 88/100 (v2, computed 2026-09-02T17:46:02.011165+00:00)
- activity 89, release rhythm 80, longevity 100
- inputs: {"age_days": 3800, "days_push": 68, "days_rel": 132, "gap_med": 5.5, "n_releases_24m": 13}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 2459, forks 297 (observed 2026-08-28T04:06:53.397592+00:00)

## What it is
A Spatie PHP package providing a HasTranslations trait that makes Laravel Eloquent model attributes translatable. Translations are stored as JSON in existing columns, requiring no extra database tables.

## Use cases
- make eloquent model attributes translatable
- store multilingual content in laravel models
- translate model fields per locale
- add multi-language support to laravel app without extra tables
- get and set translations on eloquent attributes
- fallback locale handling for missing translations

## When to choose
- you use Laravel/Eloquent and need per-attribute translations stored in JSON columns
- you want a lightweight trait-based solution with no extra translation tables
- you need locale-aware attribute access with fallback locale support

## When to avoid
- you are not using Laravel or Eloquent
- you need translation storage in separate tables or complex translation workflows
- your database is older than MySQL 5.7 and cannot use JSON columns

## Facets
- artifact type: library
- maturity: stable
- function: internationalization, orm
- domain: web-development, databases
- platform: php
- tags: eloquent, laravel-package, translations, json-columns, spatie, multilingual, localization, laravel

## Member repositories
- spatie/laravel-translatable (main) score 88

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:06:53.397592+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-30T02:29:21.807047+00:00, confidence not recorded.
  - readme: https://github.com/spatie/laravel-translatable (fetched 2026-08-28T04:06:53.397592+00:00, sha 057cb67c0741)
  - homepage: https://spatie.be/docs/laravel-translatable (fetched 2026-08-29T10:11:14.353119+00:00, sha 9ce49767bb32)
  - site_page: https://spatie.be/docs (fetched 2026-08-29T10:11:14.355648+00:00, sha 08e024d86d95)
  - site_page: https://spatie.be/about-us (fetched 2026-08-29T10:11:14.357573+00:00, sha d3cb88e4b34c)
  - site_page: https://spatie.be/docs/laravel-translatable/v6 (fetched 2026-08-29T10:11:14.359549+00:00, sha 9ce49767bb32)
  - site_page: https://spatie.be/docs/laravel-translatable/v6/support-us (fetched 2026-08-29T10:11:14.361588+00:00, sha 345062b520c9)
  - site_page: https://spatie.be/docs/laravel-translatable/v6/requirements (fetched 2026-08-29T10:11:14.363961+00:00, sha a43d042e7213)
  - site_page: https://spatie.be/docs/laravel-translatable/v6/upgrading (fetched 2026-08-29T10:11:14.366286+00:00, sha c0b68b303de2)
  - site_page: https://spatie.be/docs/laravel-translatable/v6/installation-setup (fetched 2026-08-29T10:11:14.368359+00:00, sha f505efa577cd)
  - site_page: https://spatie.be/docs/laravel-translatable/v6/questions-issues (fetched 2026-08-29T10:11:14.370251+00:00, sha 89b48b264941)
- Data as of 2026-08-30T08:39:29.467469+00:00.
