---
title: "Deploy LibreTranslate"
description: "Private machine translation API and web interface with local models."
category: "AI/ML"
url: https://railway.com/deploy/libretranslate-3
---

# Deploy LibreTranslate

Private machine translation API and web interface with local models.

**[Deploy LibreTranslate on Railway](https://railway.com/template/libretranslate-3)**

- **Creator:** Agaz Self-Host
- **Category:** AI/ML

## Template content

### LibreTranslate https://raw.githubusercontent.com/LibreTranslate/LibreTranslate/v1.6.5/libretranslate/static/icon.svg

- **Image:** libretranslate/libretranslate:v1.6.5
- **Start command:** `/bin/sh -c "chown -R 1032:1032 /home/libretranslate/.local && exec ./venv/bin/python -c 'import os; os.setgroups([]); os.setgid(1032); os.setuid(1032); from libretranslate.api_keys import Database; Database(os.environ[\"LT_API_KEYS_DB_PATH\"]).add(60, os.environ[\"LT_API_KEY\"], int(os.environ[\"LT_CHAR_LIMIT\"])); os.execv(\"./venv/bin/libretranslate\", [\"libretranslate\", \"--host\", \"*\"])'"`
- **Health check:** /languages
- **Public domain:** Yes

## Documentation

# Deploy and Host LibreTranslate on Railway

LibreTranslate is a free and open-source machine translation API and web interface powered by Argos Translate. It runs language models locally instead of sending text to proprietary translation providers, giving applications and people a private REST API for translation, language detection, and multilingual workflows.

[![Deploy on Railway](https://railway.com/button.svg)](https://railway.com/deploy/libretranslate-3)

**Published on the Railway marketplace:** https://railway.com/deploy/libretranslate-3 (`libretranslate-3`). See [TEMPLATE.md](./TEMPLATE.md) for the publication record and authoritative variable package.

## About Hosting LibreTranslate

Hosting LibreTranslate requires one CPU-based application container, a public HTTPS endpoint, persistent model storage, and limits that prevent an exposed translation API from becoming an unbounded compute service. This template pins the Umbrel-tested `libretranslate/libretranslate:v1.6.5` image, targets port `5000`, and stores Argos models, caches, and the API-key database under one Railway volume at `/home/libretranslate/.local`. It loads only English, Spanish, French, and German, uses two threads, disables file translation, caps request size and batch count, and rejects anonymous translations. Railway generates one API key per deployment, while `/languages` remains available for health checks and the web interface remains available for authorized translation.

## Common Use Cases

- Adding private machine translation to internal tools, support systems, or content workflows
- Translating text through a self-hosted REST API without sending it to a proprietary provider
- Providing a lightweight browser translation interface for a small authorized team

## Dependencies for LibreTranslate Hosting

- One Railway persistent volume mounted at `/home/libretranslate/.local`
- One Railway-generated HTTPS service domain targeting port `5000`
- Argos Translate language models for English, Spanish, French, and German

### Deployment Dependencies

- [LibreTranslate v1.6.5 documentation and settings](https://github.com/LibreTranslate/LibreTranslate/blob/v1.6.5/README.md)
- [LibreTranslate API-key management](https://docs.libretranslate.com/guides/manage_api_keys/)
- [Umbrel LibreTranslate package](https://github.com/getumbrel/umbrel-apps/tree/master/libretranslate)
- [Railway volume permissions](https://docs.railway.com/volumes#permissions)

## Implementation Details

| Service | Image | Networking and health | Persistent storage |
| --- | --- | --- | --- |
| `LibreTranslate` | `libretranslate/libretranslate:v1.6.5` | Public port `5000`; health check `/languages`; anonymous translations limited to zero; generated API key receives 60 requests/minute | `/home/libretranslate/.local` for Argos models, caches, and `api_keys.db` |

`LT_LOAD_ONLY=en,es,fr,de` bounds startup time, disk use, and memory demand instead of downloading every available model. `LT_CHAR_LIMIT=5000`, `LT_BATCH_LIMIT=10`, `LT_THREADS=2`, and disabled file translation further bound public resource use. The startup command uses Railway's documented root volume access only to repair ownership, then launches LibreTranslate as its image user, UID/GID `1032`. It inserts the Railway-generated `LT_API_KEY` into LibreTranslate's supported SQLite key database without logging the key. This template includes no reverse proxy, scraper, model-serving sidecar, or third-party translation provider.

## Why Deploy LibreTranslate on Railway?

Railway is a singular platform to deploy your infrastructure stack. Railway will host your infrastructure so you don't have to deal with configuration, while allowing you to vertically and horizontally scale it.

By deploying LibreTranslate on Railway, you are one step closer to supporting a complete full-stack application with minimal burden. Host your servers, databases, AI agents, and more on Railway.


## Similar templates

- [Chat Chat](https://railway.com/deploy/-WWW5r) — Chat Chat, your own unified chat and search to AI platform.
- [stella](https://railway.com/deploy/stella) — Self-host stella with web, API, Postgres, Redis, and object storage.
- [Hermes Agent | OpenClaw Alternative with Dashboard](https://railway.com/deploy/hermes-agent-or-openclaw-alternative-wit) — Self-Hosted Hermes AI Agent for Telegram, Discord & Slack

Open this page in a browser: https://railway.com/deploy/libretranslate-3
