Convert Kurdish Text to Speech in Your App

This tutorial takes you from zero to a playable Kurdish WAV file in about ten lines of code. It works for Sorani (Arabic script), Kurmanji (Latin script) and Badini (Arabic script), and with a V6 voice another 23 languages, using the same HTTP API that powers kurdishtts.com — no SDK required, any language that can make an HTTP request works.

Step 1 — Get a free TTS API key

Create a free account at kurdishtts.com and generate a TTS key in Settings → API. The free tier includes 20,000 characters — billing is per character of input text. Keep the key server-side; never ship it in client code.

Step 2 — Make the request

One POST to /api/tts-proxy with your text and a voice id. The response body is the WAV audio. curl:

curl -X POST https://www.kurdishtts.com/api/tts-proxy \
  -H "x-api-key: YOUR_TTS_KEY" \
  -H "content-type: application/json" \
  -d '{"text": "سڵاو، چۆنی؟", "speaker_id": "sorani_85"}' \
  --output hello.wav

Python:

import requests

resp = requests.post(
    "https://www.kurdishtts.com/api/tts-proxy",
    headers={"x-api-key": "YOUR_TTS_KEY"},
    json={"text": "سڵاو، چۆنی؟", "speaker_id": "sorani_85"},
)
resp.raise_for_status()

with open("hello.wav", "wb") as f:
    f.write(resp.content)
print("Saved hello.wav")

JavaScript (Node 18+):

import { writeFile } from "node:fs/promises";

const resp = await fetch("https://www.kurdishtts.com/api/tts-proxy", {
  method: "POST",
  headers: {
    "x-api-key": process.env.KURDISHTTS_TTS_KEY,
    "content-type": "application/json",
  },
  body: JSON.stringify({ text: "سڵاو، چۆنی؟", speaker_id: "sorani_85" }),
});
if (!resp.ok) throw new Error(await resp.text());

await writeFile("hello.wav", Buffer.from(await resp.arrayBuffer()));
console.log("Saved hello.wav");

Play hello.wav — you should hear «سڵاو، چۆنی؟» (“Hello, how are you?”) in a natural Sorani voice.

Step 3 — Pick a voice

The voice catalog is public — no key needed. For Kurdish voices the dialect is derived from the id prefix (sorani_ / kurmanji_ / badini_):

curl "https://www.kurdishtts.com/api/get-speakers?model_version=v3"

On the free tier use sorani_85, sorani_214, kurmanji_6 or kurmanji_12, plus badini_story_m and badini_narrator_f for Badini. Paid plans unlock the full legacy catalogs — up to 664 voices with"model_version": "v4" — plus the 20 curated v5 voices and all six Badini narrators with "model_version": "v5". Every catalog is rendered by V6; the field now selects voices and plan entitlement, not an older engine. A badini_ id is the exception: it belongs to no other catalog, so it works whatever model_version you send.

Want another language? List ?model_version=v6 for the V6 voices (global_1 to global_34) and send the language as dialect, for example "speaker_id": "global_1", "dialect": "de", "model_version": "v6". The free tier includes global_1 (Zana) and global_2 (Bahar); Developer, Pro and Business get every V6 voice. Word timestamps stay Kurdish only. The language table lists the 23 codes.

Useful options & limits

  • speed (0.25–4, higher = faster) and include_timestamps (Kurdish only: returns JSON with word-level timings + base64 audio) — full parameters in the API reference.
  • Sound tags: put [laugh], [chuckle], [sigh], [gasp], [cough] or [sniff] in the text, for example "Silav, tu çawa yî? [laugh]", and the voice makes that sound. Other bracketed words are not spoken. See Sound tags in the API reference.
  • Switching language: put [lang:en] (or another language code) in the text and what follows is read in that language until the next tag. It needs a V6 voice for any language other than Kurdish. See Switch language inside the text.
  • Max text per request: 500 characters free, 5,000 on paid plans. When the quota runs out the API returns 403 with an upgrade link — see pricing.
  • Building with an AI agent instead of code? Connect the MCP server to Claude.