Language detection API

Know the language of every message.

Send any text and get its language back in under a millisecond, with a confidence score you can act on. Route support tickets, filter spam, translate the right content.

  • 176languages
  • < 1 msper text
  • Free planno card needed

Try it with any text

Try:

Every message gets sorted by language.

Each response names the most likely language, its confidence, and the runners-up. Long, clean sentences score high; very short or mixed text scores low, so you know when to double-check.

MessageWhat the API seesLanguage
Où est la gare, s'il vous plaît ?French, 99% confidence. A full sentence gives the model plenty to go on.FRENCH
मुझे यह उत्पाद बहुत पसंद आया।Hindi, 99% confidence. Every script is supported, from Devanagari to Arabic, Cyrillic and Han.HINDI
Ich habe meine Bestellung noch nicht erhalten.German, 98% confidence. Route it straight to your German-speaking support queue.GERMAN
Hola! Thanks for the quick replyTwo close candidates. Mixed-language text returns both, so you can treat it as either.MIXED
okToo short to be sure. Confidence is low and reliable is false, so you can fall back to a default.UNCERTAIN
12345 !!!No letters at all. Returns und (undetermined) instead of guessing.NONE

Fast where it matters

The model stays loaded in memory, so a typical sentence is detected in well under a millisecond.

Confidence you can act on

Every answer has a 0–1 confidence score and a reliable flag, so you decide when to trust it.

Bulk when you need it

Send up to 100 texts per request. Each text uses one credit.

Add it in one request.

Send your key in the X-API-Key header. Your remaining quota comes back in every response.

Request

curl -G "https://api.example.com/v1/detect" \
  --data-urlencode "text=Où est la gare ?" \
  -H "X-API-Key: YOUR_KEY"

Response

{
  "language": "fr",
  "name": "French",
  "confidence": 0.9912,
  "reliable": true,
  "candidates": [ … ],
  "took_ms": 0.21
}

Pick the volume you need.

Paid plans are billed yearly. Your monthly quota resets on the day you activated, every month.

Questions

What counts as one request?

Each text checked uses one credit. A bulk request with 50 texts uses 50. Checking your usage with /v1/usage is free.

How long can a text be?

Up to 5,000 characters per text. One or two sentences is enough for a confident answer; very short texts (a word or two) may come back with reliable: false.

When does my quota reset?

Every month on your activation date. If you activated on the 15th, your quota resets on the 15th of each month. If you activated on the 31st, it resets on the last day of shorter months.

What happens when I run out?

Requests return 429 with a link to upgrade. Nothing is charged automatically. Upgrades apply immediately and keep this month's usage.

What if my renewal payment fails?

Your key keeps working for 3 days after expiry while you update your card, so your app never breaks without warning.

Do you store the texts I send?

No. Texts are analysed in memory and never stored or logged. Your dashboard only keeps counts per language.