- self-hosted
- tts
- guide
- open-source
- local
- deployment
Cloud TTS APIs like ElevenLabs, Google Cloud TTS, and Azure Speech are powerful β but they cost per character, require internet, and send your text to third-party servers.
Running TTS on your own hardware eliminates all three trade-offs. Once youβve downloaded the model weights, everything runs locally: no ongoing costs, no rate limits, and your text never leaves your machine.
This guide covers every major self-hosted TTS engine you can run on a personal PC or home server in 2026 β from a single pip install
to full Docker deployments with voice cloning.
Quick Reference #
| TTS Engine | Quality | GPU Needed | Install | License | Voice Cloning | Languages | Parameter Count |
|---|---|---|---|---|---|---|---|
| Kokoro 82M | β β β β β | No | pip install kokoro |
Apache 2.0 | β | 9 | 82M |
| Piper | β β β ββ | No | pip install piper-tts |
MIT / GPL | β | 20+ | Varies |
| MeloTTS | β β β β β | No | pip install MeloTTS |
MIT | β | 6 | Small |
| F5-TTS | β β β β β | Recommended | pip install f5-tts |
CC-BY-NC | β (5s) | 4 | 330M |
| CosyVoice 2/3 | β β β β β | Recommended | git clone + pip |
Apache 2.0 | β Zero-shot | 9+18 dialects | 0.5B |
| Fish Speech 1.6 | β β β β β | Recommended | pip install fish-speech |
CC-BY-NC-SA | β (10s) | 13 | 500M |
| Zonos/Zonos2 | β β β β β | Yes (GPU) | pip install zonos |
Apache 2.0 | β | 8 | 1.6B / 8B |
| ChatTTS | β β β β β | Recommended | pip install chattts |
CC-BY-NC | β | 2 | ~400M |
| GPT-SoVITS | β β β β β | Yes (GPU) | git clone + webui |
MIT | β (5s) | 4 | ~1B |
| Chatterbox | β β β β β | Yes (GPU) | pip install chatterbox |
MIT | β Zero-shot | 5 | ~1B |
| OuteTTS | β β β β β | Optional | pip install outetts |
Apache 2.0 | β | 4 | 0.6B / 1B |
| Edge-TTS | β β β ββ | No | pip install edge-tts |
MIT | β | 100+ | (Cloud via Edge) |
Tier 1: Lightweight β Runs on CPU, No GPU Required #
These engines run comfortably on any modern PC with just a CPU. Ideal for quick setups, batch processing, and always-on home servers.
Kokoro TTS β Best Quality-to-Size Ratio
Kokoro is the standout lightweight TTS of 2026. With just 82 million parameters, it produces speech quality comparable to mid-tier cloud APIs (MOS 4.3β4.5). Apache 2.0 licensed β use it for anything.
pip install kokoro
python
from kokoro import KPipeline
pipeline = KPipeline(lang_code='a') # American English
for gsps, ps, audio in pipeline("Hello, this is a self-hosted TTS test.", voice='af_heart'):
pass
Key facts:
54 voices across American English, British English, Japanese, Mandarin Chinese, Spanish, French, Hindi, Italian, and Brazilian PortugueseRuns faster than realtime on CPUβ a modern laptop generates ~2x realtime** Apache 2.0**β commercial use, no restrictions** ONNX-based**β can be optimized with onnxruntime for GPU if desired** FastAPI server**available:fastkokorogives you an OpenAI-compatible TTS API endpoint
Best for: Batch audio generation, home server TTS API, audiobook production, integration into local apps.
Piper TTS β The Raspberry Pi Champion
Piper is the fastest neural TTS engine for CPU inference. Originally developed by the Rhasspy team for Home Assistant, itβs now maintained by the Open Home Foundation.
pip install piper-tts
echo "Local TTS on your own hardware." | piper \
--model en_US-libritts_r-medium \
--output-raw | aplay --rate 22050 --format FLOAT32
Key facts:
900+ English voices, plus multilingual support** 22kHz output**, optimized for speed over fidelity** Works on Raspberry Pi 4**β faster than realtime on a $35 board** Licensing note:**Original rhasspy/piper (MIT) was archived in Oct 2025. Active fork is OHF-Voice/piper1-gpl (GPL-3.0). The old MIT voices/weights remain usable.Wyoming Protocolβ integrates natively with Home Assistant
Best for: Home Assistant voice pipelines, embedded systems, CLI workflows, accessibility tools.
MeloTTS β Fast Multilingual CPU TTS
MeloTTS by MIT and MyShell.ai is designed for real-time CPU inference with multilingual support. Very easy to install:
pip install MeloTTS
python
from melo.api import TTS
model = TTS(language='EN')
model.tts_to_file("Self-hosted TTS is easy.", speaker_id=0, output_path='output.wav')
Key facts:
- Supports English, Mandarin Chinese, Japanese, Korean, French, Spanish - Mixed Chinese/English support Real-time CPU inference on modern laptops- Very small model footprint
Best for: Multilingual TTS on CPU-only hardware, quick prototyping, language learning tools.
Edge-TTS β Microsoftβs TTS, Locally
Edge-TTS is a Python library that taps into Microsoft Edgeβs online TTS service. Technically it needs internet for each request, but itβs the easiest way to get 100+ high-quality voices across dozens of languages with zero model download and zero character limits.
pip install edge-tts
edge-tts --text "Hello from self-hosted TTS" --voice en-US-JennyNeural --write-media output.mp3
Key facts:
100+ voices across 50+ languagesNo GPU needed, no model downloads** Requires internet**β it calls Microsoftβs servers (not truly offline)** Free and unlimited**β no API key, no rate limiting observed
Best for: Quick TTS on any machine, when you want wide language coverage and donβt need absolute privacy.
Tier 2: GPU Recommended β Higher Quality & Voice Cloning #
These engines benefit significantly from a GPU (NVIDIA with 6GB+ VRAM recommended), but many still work on CPU at reduced speed.
F5-TTS β Zero-Shot Voice Cloning
F5-TTS (14K+ stars) uses flow matching to generate speech from a 5β15 second reference clip. Itβs the current state-of-the-art open-source voice cloning system for its size.
pip install f5-tts
f5-tts_infer-gradio --port 7860 --host 0.0.0.0
Or via Docker:
docker run -it --gpus=all -p 7860:7860 ghcr.io/swivid/f5-tts:main
Key facts:
Zero-shot voice cloning from 5 seconds of audioMultilingualβ English, Chinese, Japanese, Korean** 330M parameters**β efficient for the quality** Gradio WebUIincluded for easy testing License:**CC-BY-NC 4.0 (non-commercial β fine for personal use)
Best for: Voice cloning experiments, audiobook character voices, custom TTS for personal projects.
CosyVoice 2 & 3 β Alibabaβs Streaming TTS
CosyVoice by Alibabaβs FunAudioLLM team is a top-tier multilingual TTS system with support for streaming, zero-shot voice cloning, and emotion control. CosyVoice 3 (0.5B params, Dec 2025) added 18 Chinese dialects alongside 9 languages.
git clone https://github.com/QwenAudio/CosyVoice
cd CosyVoice
pip install -r requirements.txt
python -c "from modelscope import snapshot_download; snapshot_download('FunAudioLLM/Fun-CosyVoice3-0.5B-2512', local_dir='pretrained_models/CosyVoice3-0.5B')"
python webui.py --port 8000
Key facts:
9 languages+** 18 Chinese dialects**(CosyVoice 3)** Zero-shot voice cloningfrom a short reference Streaming mode**β near-lossless streaming synthesis** Apache 2.0 license**β permissive** 0.5B parameters**β relatively compact for the quality** Instruct TTS**β control style, emotion, and speaking rate via text prompts
Best for: High-quality multilingual TTS, Chinese-focused applications, streaming voice applications.
Fish Speech 1.6 β Multilingual SOTA
Fish Speech by Fish Audio is trained on over 1 million hours of multilingual data. Version 1.6 added emotion tagging and improved expressiveness.
pip install fish-speech
huggingface-cli download fishaudio/fish-speech-1.6 --local-dir ./fish-speech-1.6
python tools/tts.py --text "Hello, this is Fish Speech." --output output.wav
Key facts:
13 languagesβ broad multilingual support** Voice cloningfrom 10 seconds of audio Emotion tags**β control emotion through text markup** 200K+ community voicesavailable through their voice library License:**CC-BY-NC-SA 4.0 (non-commercial, share-alike)
Best for: Expressive multilingual TTS, podcast/dubbing projects, voice cloning with minimal samples.
Zonos & Zonos2 β The ElevenLabs Rival
Zonos by Zyphra (Apache 2.0) was trained on 200K+ hours of multilingual speech. Its successor Zonos2 (8B parameters, June 2026) introduced a Mixture-of-Experts architecture and achieves quality competitive with top proprietary TTS providers.
pip install zonos
git clone https://github.com/Zyphra/Zonos2
cd Zonos2
pip install -r requirements.txt
python infer.py --model Zonos2-8B --text "Self-hosted TTS at its best."
Key facts:
Apache 2.0 licenseβ free for any use** Zonos2 (8B MoE)β competitive with ElevenLabs Turbo v2 in quality Voice cloningbuilt in Docker supportfor easy deployment GGUF supportin Zonos2 for CPU + cross-platform inference Mini-SGLang inference server**for high-throughput production
Hardware: Zonos v0.1 needs ~4GB VRAM. Zonos2 8B needs 16GB+ VRAM at FP16, or use the GGUF quantized version for CPU.
Best for: Production-quality self-hosted TTS, when you want ElevenLabs-level quality on your own hardware.
Tier 3: Specialist Tools β Dialog, Cloning, GGUF #
ChatTTS β Conversational Speech
ChatTTS is designed specifically for dialogue scenarios β think LLM assistant voices, conversational audio, and natural-sounding back-and-forth.
pip install chattts
from chattts import ChatTTS
chat = ChatTTS()
chat.load_models()
chat.infer("Hello! How can I help you today?", output_path="hello.wav")
Key facts:
Optimized for dialogueβ natural prosody for conversational text**~500M parametersEmotion and intonation controlCC-BY-NC license****CPU + GPU** support
Best for: LLM voice assistants, chatbot voice, dialogue audio.
GPT-SoVITS β The Voice Cloning Powerhouse
GPT-SoVITS (40K+ GitHub stars) combines a GPT-style text encoder with SoVITS voice synthesis. Itβs the most popular open-source voice cloning project.
git clone https://github.com/RVC-Boss/GPT-SoVITS
cd GPT-SoVITS
pip install -r requirements.txt
python webui.py --port 9874
Key facts:
Zero-shot cloning from 5 seconds of audioFew-shot fine-tuning with just 1 minute of training dataMultilingualβ Chinese, English, Japanese, Korean** All-in-one WebUI**β training, inference, voice mixing** MIT licensefor the framework code GPU recommended**(RTX 3060+)
Best for: Voice cloning projects, character voice creation, Chinese/English bilingual TTS.
Chatterbox β Zero-shot Cloning, MIT Licensed
Chatterbox by Resemble AI is a newer entrant with a permissive MIT license and zero-shot voice cloning.
pip install chatterbox
Key facts:
MIT licenseβ commercially friendly** Zero-shot voice cloningfrom reference clip Multilingual support****Fast inference** on modern GPUsGradio interface included
Best for: Commercial projects needing voice cloning, production TTS pipelines.
OuteTTS β Llama-based TTS with GGUF
OuteTTS is built on a Llama 3.2 architecture (0.6B or 1B parameters) and supports GGUF quantization, meaning it runs via llama.cpp for CPU inference.
pip install outetts
llama-tts --model OuteTTS-1.0-0.6B-Q4_K_M.gguf \
--vocoder WavTokenizer-Large-75-Q4_0.gguf \
--prompt "Hello, this is OuteTTS." \
--output output.wav
Key facts:
GGUF supportβ runs on CPU via llama.cpp** Apache 2.0 license****Speaker cloning** from reference audioVery long text supportβ automatic text splitting** Llama-server compatible**for API deployment
Best for: CPU-only deployments, llama.cpp users, systems already running GGUF models.
Deployment Architectures #
Docker: One-Command Deployments
Most modern TTS engines offer Docker images. Hereβs a comparison:
| Engine | Docker Image | Port | GPU Support |
|---|---|---|---|
| Kokoro | ghcr.io/remsky/kokoro-fastapi |
8880 | Optional |
| F5-TTS | ghcr.io/swivid/f5-tts:main |
7860 | Required |
| Zonos | ghcr.io/zyphra/zonos:latest |
7860 | Required |
| CosyVoice | Build from source | 8000 | Required |
| Piper | rhasspy/piper |
N/A (CLI) | N/A |
Sample Docker Compose for a self-hosted TTS API:
version: '3'
services:
kokoro-tts:
image: ghcr.io/remsky/kokoro-fastapi:latest
ports:
- "8880:8880"
restart: unless-stopped
OpenAI-Compatible API
Several projects expose an OpenAI-compatible TTS API endpoint, so you can drop them into any existing application:
fastkokoroβ wraps Kokoro with OpenAI TTS API,pip install fastkokoro
Local-TTS-Serviceβ multi-engine OpenAI-compatible TTS server** Zonos2 inference server**β Mini-SGLang based, OpenAI-compatible
from openai import OpenAI
client = OpenAI(
base_url="http://localhost:8880/v1",
api_key="not-needed"
)
response = client.audio.speech.create(
model="kokoro",
voice="af_heart",
input="Self-hosted TTS is the future."
)
response.stream_to_file("output.mp3")
Voice Agent Pipeline
The complete local voice agent chain (STT β LLM β TTS) on a single machine:
Mic β Whisper (STT, CPU-friendly) β Ollama/llama.cpp (LLM) β Kokoro/Piper (TTS) β Speaker
With GPU acceleration, end-to-end latency is under 1 second. On CPU, expect 2β3 seconds β still acceptable for most applications.
Choosing What to Run #
Budget / Hardware
βββ Any CPU, no GPU
β βββ Need quality? β Kokoro 82M (pip install kokoro)
β βββ Need speed? β Piper (pip install piper-tts)
β βββ Need multilingual? β MeloTTS or Edge-TTS
β βββ Need API server? β fastkokoro (OpenAI-compatible)
βββ NVIDIA GPU, 6GB+ VRAM
β βββ Need voice cloning? β F5-TTS or GPT-SoVITS
β βββ Best multilingual? β CosyVoice 3 or Fish Speech 1.6
β βββ Production quality? β Zonos2 (8B needs 16GB+)
βββ GGUF ecosystem user
βββ OuteTTS (runs via llama.cpp)
Bottom Line #
Self-hosted TTS in 2026 is genuinely practical. The quality gap with cloud APIs has narrowed to the point where most users wonβt notice the difference β and the advantages (zero cost, unlimited use, complete privacy, offline operation) are significant.
Start with Kokoro for the easiest path β itβs one pip install
away and covers the majority of use cases. Add F5-TTS or CosyVoice if you need voice cloning. Go all-in with Zonos2 if you have the GPU and want ElevenLabs-rivaling quality on your own metal.
Your voices, your hardware, your data.
This guide was updated July 24, 2026. The TTS ecosystem evolves quickly β star counts, model versions, and licensing may change. Always verify the current license on each projectβs GitHub page before commercial use.
Related articles #
Try OfflineTTS #
Four local TTS engines, Whisper transcription, and private browser audio tools.