An unlimited free Google Translate API backed by a real browser session.
This service is provided to the public for educational purposes only.
Try it out:
curl 'https://t.song.work/api?text=hello&from=en&to=zh-CN'To include pronunciation audio as data URLs for the source text, translated text, and dictionary headwords when available:
curl 'https://t.song.work/api?text=chien&from=fr&to=en&audio=true'Visit https://t.song.work/ to see more usage.
This free demo is best-effort and does not collect any data.
Translateer keeps one long-lived Google Translate page alive and executes browser-originated RPC requests from inside that page. Runtime requests do not scrape the UI; they reuse the page's live cookies and request context to fetch:
- translations
- rich details such as examples, definitions, and translation groups
- pronunciation audio
- typo correction and autocomplete suggestions
-
Clone the repository
git clone https://github.com/songkeys/translateer.git
-
Build and run Dockerfile
docker build -t translateer . docker run -d -p 8999:8999 translateer
-
Clone the repository
git clone https://github.com/songkeys/translateer.git
-
Run the server
deno task start
See the markdown table below:
| Variable | Description | Default |
|---|---|---|
PORT |
Port to listen on | 8999 |
The API returns a nested response shaped around the source side (from) and
target side (to):
{
"result": "dog",
"from": {
"pronunciation": "ʃjɛ̃",
"audio": "data:audio/mpeg;base64,...",
"dictionary": {
"headword": "chien",
"pronunciation": "ʃjɛ̃",
"audio": "data:audio/mpeg;base64,...",
"examples": ["..."],
"definitions": {
"noun": [{ "definition": "...", "example": "..." }]
},
"synonyms": {
"noun": [{ "labels": ["common"], "words": ["..."] }]
},
"related": ["..."],
"translations": {
"noun": [
{
"translation": "dog",
"reversedTranslations": ["chien"],
"frequency": "common"
}
]
}
}
},
"to": {
"pronunciation": "Kon'nichiwa",
"audio": "data:audio/mpeg;base64,...",
"dictionary": {
"headword": "dog",
"pronunciation": "dɔɡ"
}
}
}Notes:
resultis always present.from.didYouMean,from.suggestions, andfrom.detectedLanguageonly appear when Google returns them.from.audio,to.audio,from.dictionary.audio, andto.dictionary.audioonly appear whenaudio=trueand Google exposes a matching speaker payload.- For long text, Translateer chunks the request to avoid Google-side
pagination. In that mode, the API returns the stitched
resultand a stablefrom.detectedLanguagewhen all chunks agree, but does not merge audio or dictionary metadata across chunks.
An easy-to-use Raycast extension is provided. Check songkeys/raycast-extension#Translateer for more details.
