A privacy-focused Firefox extension that enables seamless web page translation through Mozhi: an open-source proxy to translation services that strips away their tracking.
Select text on any page, right-click, and get translations without being tracked. No telemetry, no analytics, no remote scripts. Inspired by DeepL translation extension but for Mozhi.
- Context Menu Translation: Right-click on selected text to translate instantly via Mozhi
- Floating Translate Button: A quick-access button appears near selected text for one-click translation
- Popup Interface: Dedicated popup for typing or pasting text to translate
- Floating Translation Box: Draggable, inline translation results displayed directly on the page
- Multiple Translation Engines: Supports Google, DeepL, Yandex, and other engines available through Mozhi
- Language Selection: Configurable source and target languages with auto-detection
- Multiple API Endpoints: Add and enable multiple Mozhi instances; one is randomly selected per translation
- Translation Cache: In memory cache (30 minutes TTL, max 100 items) to avoid redundant requests
- Dark Mode Support: Automatically adapts to your system's color scheme
- Self-Host Friendly: Use a trusted public Mozhi instance or host your own
| DeepL | Yandex | |
|---|---|---|
![]() |
![]() |
![]() |
- Open Firefox and navigate to
about:debugging - Click "This Firefox" in the sidebar
- Click "Load Temporary Add-on..."
- Select the
manifest.jsonfile from the project directory
- Click the extension icon in the toolbar
- Go to Settings and configure:
- API Endpoint: Mozhi instance URL (defaults to
https://mozhi.aryak.me) - Translation Engine: Google, DeepL, Yandex, etc.
- Source/Target Languages: Your preferred languages
- Floating Button: Enable/disable the selection button
- API Endpoint: Mozhi instance URL (defaults to
- Method 1: Select text on any webpage and click the floating button
- Method 2: Right-click selected text and choose "Translate selection with Mozhi"
- Method 3: Click the extension icon and type/paste text in the popup
| Setting | Default | Description |
|---|---|---|
| API Endpoint | https://mozhi.aryak.me |
Mozhi instance URL |
| Engine | google |
Translation engine (google, deepl, yandex, etc.) |
| Source Language | auto |
Auto-detect or specific language code |
| Target Language | en |
Target language code |
| Show Selection Button | true |
Show floating button after text selection |
| Remember Last Used | false |
Use last translation config instead of defaults |
This extension is designed with privacy as the core principle:
- No telemetry: The extension author collects no data
- No analytics: No usage tracking of any kind
- No remote scripts: All code runs locally in your browser
- User-controlled endpoints: You choose which Mozhi instance to trust, or self-host your own
- Local settings: All configuration is stored locally via
browser.storage.local - Translation cache: Stays in memory and can be cleared from the options page
- User selects text on a webpage
- The content script detects the selection and offers translation via floating button or context menu
- The background script receives the text and calls the configured Mozhi API endpoint
- Mozhi proxies the request to the selected translation engine (Google, DeepL, etc.) without forwarding tracking data
- The translation result is displayed in a draggable floating box on the page
background.js: API communication, caching, settings management, context menucontent.js: Page injection, UI rendering, text selection handlingpopup.html/js: Quick translation interface in the toolbaroptions.html/js: Configuration page for endpoints, languages, and behavior
- JavaScript (ES6+): Core extension logic
- HTML5 & CSS3: UI structure and styling with dark mode support
- Firefox WebExtensions API:
browser.runtime,browser.storage,browser.contextMenus, etc. - Shadow DOM: Isolated UI rendering for translation components
- Mozhi API: Translation proxy service
mozhiTranslateFirefox/
├── manifest.json # Extension manifest
├── background.js # Background script (API, caching, context menu)
├── content.js # Content script (page injection, UI, selection)
├── content.css # Content styles
├── popup.html # Popup UI
├── popup.js # Popup logic
├── popup.css # Popup styles
├── options.html # Options page UI
├── options.js # Options page logic
├── options.css # Options page styles
├── icons/
│ ├── mozhi-48.png # Toolbar icon (48 px)
│ ├── mozhi-96.png # Toolbar icon (96 px) and UI logo
│ └── mozhi-128.png # Add-on listing icon (128 px)
└── screenshots/ # Listing screenshots (not packaged)
- Mozhi: codeberg.org/aryak/mozhi: The open-source translation proxy that powers this extension
This project uses MIT License.
Note: This is an unofficial extension. Mozhi is developed independently at codeberg.org/aryak/mozhi.



