PHPackages                             vectorwyse/locale-switcher - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. vectorwyse/locale-switcher

ActiveLibrary[Localization &amp; i18n](/categories/localization)

vectorwyse/locale-switcher
==========================

Adds locale switching to a Laravel project

v1.3(6y ago)34.4k↓30.4%MITPHP

Since Jun 5Pushed 6y ago1 watchersCompare

[ Source](https://github.com/vectorwyse/laravel-locale-switcher)[ Packagist](https://packagist.org/packages/vectorwyse/locale-switcher)[ RSS](/packages/vectorwyse-locale-switcher/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (4)DependenciesVersions (6)Used By (0)

Laravel Locale Switcher
=======================

[](#laravel-locale-switcher)

> Adds locale switching to a Laravel project.

Give users ability to toggle between languages. Provides template for language dropdown. Selected language will be saved to the database.

[![](screenshot.png)](screenshot.png)

Installation
------------

[](#installation)

```
composer require vectorwyse/locale-switcher
php artisan migrate
```

Usage
-----

[](#usage)

Add list of supported locales and descriptions in `config/app.php`. Make sure you have all the language files!

```
'available_locales' => [
    'en' => 'English',
    'es_es' => 'Español',
    'zh_TW' => '中文',
],
```

### Nova

[](#nova)

If you are using Nova, add the following to your header template:

```
@include('locale-switcher::nova-dropdown')
```

This will add a `` component. If you would like to style any of the elements within the template, pass in an `$attributes` array. We currently only support the elements listed below:

```
@include('locale-switcher::nova-dropdown', ['attributes' => [
    'dropdown' => ['class' => 'ml-auto h-9 flex items-center dropdown-right'],
    'dropdown-trigger' => ['class' => 'h-9 flex items-center text-90'],
    'dropdown-menu' => ['width' => '200', 'direction' => 'rtl'],
    'a' => ['class' => 'block no-underline text-90 hover:bg-30 p-3'],
]])
```

If you would like to override the existing template completely and style your own, put the code in `resources/views/vendor/locale-switcher/nova-dropdown.blade.php`

### Vanilla HTML

[](#vanilla-html)

Coming soon!

Support Us
----------

[](#support-us)

[Vectorwyse](https://vectorwyse.com) is a digital agency offering advisory and web development services. We love building things with Laravel and Vue.js, so when we have an opportunity to give back to the community, we're super excited!

If you find this package useful, or if you would like us to build something for you, feel free to [drop us a line!](mailto:hello@vectorwyse.com)

###  Health Score

33

—

LowBetter than 75% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity26

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 92.9% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~56 days

Total

4

Last Release

2372d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/4dcf578e60ccbe9e62ece1c56df737c8a5bddb421a124b8eabc0d8e8b23e6136?d=identicon)[vectorwyse](/maintainers/vectorwyse)

---

Top Contributors

[![jelib3an](https://avatars.githubusercontent.com/u/50533338?v=4)](https://github.com/jelib3an "jelib3an (13 commits)")[![samrodrigues](https://avatars.githubusercontent.com/u/16259394?v=4)](https://github.com/samrodrigues "samrodrigues (1 commits)")

### Embed Badge

![Health badge](/badges/vectorwyse-locale-switcher/health.svg)

```
[![Health](https://phpackages.com/badges/vectorwyse-locale-switcher/health.svg)](https://phpackages.com/packages/vectorwyse-locale-switcher)
```

###  Alternatives

[joedixon/laravel-translation

A tool for managing all of your Laravel translations

717911.4k11](/packages/joedixon-laravel-translation)[illuminate/translation

The Illuminate Translation package.

6936.4M495](/packages/illuminate-translation)[lajax/yii2-translate-manager

Translation management extension for Yii 2

227578.8k13](/packages/lajax-yii2-translate-manager)[larswiegers/laravel-translations-checker

Make sure your laravel translations are checked and are included in all languages.

256423.2k2](/packages/larswiegers-laravel-translations-checker)[inpsyde/multilingual-press

Simply THE multisite-based free open source plugin for your multilingual websites.

2414.0k1](/packages/inpsyde-multilingual-press)[statikbe/laravel-chained-translator

The Laravel Chained Translator can combine several translators that can override each others translations.

36149.4k6](/packages/statikbe-laravel-chained-translator)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
