xAI Custom Voices API for Text to Speech
Clone and use custom voices in xAI's TTS and Speech to Speech APIs.
Custom Voices API
Cloning a voice from a short audio sample (up to 120 seconds) and using it in text-to-speech and speech-to-speech applications via API.
Free for up to 30 custom voices in the console. Enterprise plan required for API access.
https://docs.x.ai/developers/model-capabilities/audio/custom-voices
Clone a voice from a short audio clip and use it with xAI's Text to Speech and Speech to Speech APIs. The feature is available in the US (except Illinois) and allows for custom voice IDs to be used interchangeably with built-in voices.
The model captures not just the timbre but also the delivery patterns of the reference clip. Matching the recording to the intended use case yields better results.
- Custom Voices ↗xAI · xAI Docs: Guides · Aug 3, 2026 · paraphrased
First seen on Subvolts Aug 3, 2026. Updated Sep 11, 2026. Spotted a problem? Tell us.
- Custom VoicesxAI · xAI Docs: Guides · Aug 3, 2026
The Playbook: reusable how-tos, prompts, configs and tips pulled out of the news.
- ChecklistBest practices for custom voice reference clipsMatch recording quality and content to intended use for optimal custom voice results. · 5 min
- HeuristicAutomatic language detection in Gemini 3.8 TTSGemini 3.8 TTS automatically detects input language, supporting over 100 languages. · 1 min
- Model pickChoose Gemini 3.8 Flash-Lite TTS for production workloadsSelect Gemini 3.8 Flash-Lite TTS for high-throughput production needs, replacing older preview models. · 5 min
- Code snippetUse custom voice in xAI Text to Speech APIPass the custom voice_id as the 'voice' query parameter in TTS API calls. · 3 min
- HeuristicChoose the best voice personality for your applicationSelect built-in voices based on their unique personality and tone to best match your application's needs. · 5 min
- Safety tipNever expose API keys in client-side codeAlways proxy WebSocket connections through your backend to protect your API keys from exposure. · 10 min
Questions people ask
- Which AI tools does this work with?
- The sources used it with Grok.
- Where did this come from?
- xAI (xAI Docs: Guides). Subvolts collected, normalized and credited it; the link above opens the original.

