Skip to content
Lokalise CLI v2
Go Makefile
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.
cmd added checkFlag function Nov 1, 2019
dist Directory prefix empty can be passed Oct 22, 2019
docs 2.03 Oct 22, 2019
.gitignore 2.02 Oct 21, 2019
Makefile Makefile fixes Oct 15, 2019 Update Oct 22, 2019
go.mod Directory prefix empty can be passed Oct 22, 2019

Lokalise CLI v2

Getting started

Lokalise CLI v2 allows you to manipulate any object or data in your Lokalise workspace, which includes files, projects, keys, translations, comments, contributors, teams and more.

Whats new in v2?

This version of CLI tool has been completely rebuilt from scratch and is not compatible with the v1 CLI command syntax. Instead of being just an upload/download tool this release supports all Lokalise API v2 endpoints.


Get the binaries for your platform, unarchive and put into any executable folder. All set!


Install using Homebrew:

brew tap lokalise/cli-2
brew install lokalise2

or get the binaries:





See DockerHub for more information.


All endpoints require the --token parameter. You can generate your API token in Personal profile. Note, the token is personal and mimics your access level on team and project level. If you require a user-independent API token, create a separate user in your team (e.g. API user), set proper access rights and use this user's token.

Passing the flags


All boolean flags must be passed via the = sign, i.e. --original-filenames=false.


Flags of type strings should be comma-delimited, i.e. --include-tags=one,two.

JSON objects

Some flags require a JSON-encoded object passed as string, i.e. --languages='[{"lang_iso":"en","custom_iso":"en-us"},{"lang_iso":"en_GB","custom_iso":"en-gb"}]'. There is an online tool to help you with the escaping.


Run lokalise2 --help from the terminal to see the list of commands and subcommands. Run lokalise2 command subcommand --help to see the help page.



Download files from Lokalise

lokalise2 \
    --token <token> \
    --project-id <project_id> \
    file download \
    --format json \
    --unzip-to ./locales

Upload a file to Lokalise

lokalise2 \
    --token <token> \
    --project-id <project_id> \
    file upload \
    --file /tmp/en.json \
    --lang-iso en


If you are using project branching feature in Lokalise, simply add branch name separated by semicolon to the project ID in any command to access the branch, i.e. 3002780358964f9bab5a92.87762498:feature/new-release.

Config file

Optionally, you may rename included config-example.yml to config.yml and set various CLI tool parameters like token or timeouts.


2.03 (October 22, 2019)

Endpoint parameter fixes.

2.00 (October 15, 2019)

Initial release.

You can’t perform that action at this time.