DEV Community

AriaieBOY
AriaieBOY

Posted on • Originally published at ariaieboy.ir

1

Translate Your Laravel Application to 78 Languages

Laravel has localization tools that help you translate your applications into any language you want.
But by default, all the Laravel Lang files include the English language. And if your application needs other languages you must create and manage lang files for each language by yourself.

Right now that I am writing this article we have more than 1400 keys for each language in the Laravel-Lang package that includes Laravel and its first-party packages.

You can translate Laravel and its packages like Jetstream, Fortify, Cashier, etc into 78 Languages.

All you need to do is to install Laravel-lang/common packages using the command below:

composer require laravel-lang/common --dev
Enter fullscreen mode Exit fullscreen mode

After that you can add any languages you want using the command below:

php artisan lang:add en de ro zh_CN lv
Enter fullscreen mode Exit fullscreen mode

Laravel often introduces new localization keys to the lang files and the community might update the translations in the future you can update the added languages using the command below:

php artisan lang:update
Enter fullscreen mode Exit fullscreen mode

You can translate missing keys or improve the translations and create a PR on the Laravel-Lang/lang and help improve this package.

Billboard image

Imagine monitoring that's actually built for developers

Join Vercel, CrowdStrike, and thousands of other teams that trust Checkly to streamline monitor creation and configuration with Monitoring as Code.

Start Monitoring

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Discover a treasure trove of wisdom within this insightful piece, highly respected in the nurturing DEV Community enviroment. Developers, whether novice or expert, are encouraged to participate and add to our shared knowledge basin.

A simple "thank you" can illuminate someone's day. Express your appreciation in the comments section!

On DEV, sharing ideas smoothens our journey and strengthens our community ties. Learn something useful? Offering a quick thanks to the author is deeply appreciated.

Okay