Text to MP3 Free API

Create speech and download audio using the API.

Last updated

The API is available on Starter, Pro, and Business plans. Create an API key in the dashboard and send it as Authorization: Bearer $API_KEY. A key is shown once when created.

Create a job with JSON containing text, voice, format (mp3 or wav):

curl https://texttomp3free.com/api/v1/speech \
  -H "Authorization: Bearer $API_KEY" -H "Content-Type: application/json" \
  -d '{"text":"Hello there.","voice":"af_heart","format":"mp3"}'

A successful request returns status 202 with id and status_url. Poll the URL until status is COMPLETED or FAILED. The response also includes progress, characters_charged, duration_s, voice, and format.

curl "https://texttomp3free.com/api/v1/jobs/$JOB_ID" -H "Authorization: Bearer $API_KEY"
curl "https://texttomp3free.com/api/v1/jobs/$JOB_ID?download=1" \
  -H "Authorization: Bearer $API_KEY" -o speech.mp3

Available voices: af_heart (Heart), af_bella (Bella), bf_emma (Emma), am_michael (Michael), af_nicole (Nicole), af_aoede (Aoede), af_kore (Kore), af_sarah (Sarah), am_fenrir (Fenrir), and am_puck (Puck).

Plan Characters per month Characters per request Retention Batch
Starter 500,000 50,000 7 days 10
Pro 1,800,000 100,000 30 days 50
Business 4,500,000 100,000 30 days 50

Characters are counted after tags, URLs and symbols are removed, entities decoded, and whitespace collapsed. Each request body is limited to four times the plan's per-request character cap plus 4,096 bytes. All paid plans have ten voices, MP3 and WAV, and two concurrent jobs per account. Business jobs have priority. The account rate limit is 60 requests per 60-second window across keys. A rate-limit refusal does not charge characters. The Retry-After header gives seconds until reset.

Errors are JSON with error and message. Values in braces vary by request.

Status Error Message
400 speech_failed Invalid request., There is no text to read., Format must be mp3 or wav., or Voice must be one of: {voices}
401 unauthorized Unauthorized: send a valid API key as 'Authorization: Bearer <key>'.
402 out_of_credits This text has {characters} characters; you have {remaining} left.
403 paid_plan_required The API is on paid plans.
403 suspended This account is suspended and cannot generate audio. Your files and account data are intact. Contact [email protected] to sort it out.
404 not_found Job not found.
409 not_ready Job is not ready to download.
413 speech_failed Request body is too large. or This text has {characters} characters; the limit per request on your plan is {limit}.
422 speech_failed Only English text can be read for now.
429 rate_limited Rate limit exceeded: 60 requests per 60 seconds per account. Try again in {seconds} second{s}.
429 busy Too many requests in progress.
429 concurrency_limit 2 audio jobs are already running for this account. Wait for one to finish, then send the next. Nothing was charged for this request.
429 timeout_cooldown 3 audio jobs from this account ran out of time in the last hour. Try shorter text or wait up to an hour. Nothing was charged for this request.
429 compute_ceiling This account has reached its monthly compute limit of {amount}; it resets on {date}.
503 rate_limit_unavailable Rate limiting is unavailable right now. Please try again.
503 speech_failed The speech worker is unavailable. or The speech service is unavailable.

Every other document is listed on the docs index.