Multi-language with Switcher

Filament 4/5
Also available in Filament 3 version

Multi-language Filament implementation with three translation components: Core Filament files, Core Laravel files, and custom additions. Lithuanian language example included with translations in /lang folder and a Filament package for language switching.

NmX6Gegya5SPpVMBtG8yNuZd76jYXA-metaMTUtbXVsdGktbGFuZ3VhZ2Utc3dpdGNoZXIucG5n-

Get the Source Code:

Only This Example

$9

One-time payment

Full source code for Multi-language with Switcher
Downloadable ZIP file with the source code
Lifetime access to this example
GitHub Sign in with GitHub to buy

Sign in first, then complete your $9 checkout.

Best value — all 168 examples

FilamentExamples Membership

$99 /year
or
$199 lifetime
Access to code of all 168 examples
Future new examples and updates included
FilaCheck Pro package licence included
MCP server included
View membership plans

30-day money-back guarantee

How it works

We use a [bezhansalleh/filament-language-switch](https://filamentphp.com/plugins/bezhansalleh-language-switch) package to add a language switcher to the top navigation.

All language files are published.

php artisan lang:publish
php artisan vendor:publish --tag=filament-panels-translations

We set available languages in the AppServiceProvider.

app/Providers/AppServiceProvider.php:

use BezhanSalleh\LanguageSwitch\LanguageSwitch;
 
public function boot(): void
{
LanguageSwitch::configureUsing(function (LanguageSwitch $switch) {
$switch
->locales(['lt','en']);
});
}

In the Resource, we use the translateLabel() method to translate labels. It makes, for example, Title to a __('Title').

The FULL tutorial is available after the purchase: in the Readme file of the official repository you would get invited to.