Video coming soon…
🤖 Setup Kokoro TTS — Fast Local Text-to-Speech API
Deploy Kokoro TTS on Ubuntu with Docker — a fast, high-quality, OpenAI-compatible text-to-speech API you can run on a CPU, perfect as a voice backend for Open WebUI, on port 8880.
⚠️ This script is provided for demo and testing purposes only. Not intended for production use.
📦 Resources & Setup Scripts
Grab the automated bash script from GitHub to follow along with the video.
Quick Install:
wget https://raw.githubusercontent.com/mhmdali94/Docker/main/ai/kokoro/kokoro-ubuntu.sh
chmod +x kokoro-ubuntu.sh
sudo bash kokoro-ubuntu.sh
Tutorial Steps
1 Download the Script
wget https://raw.githubusercontent.com/mhmdali94/Docker/main/ai/kokoro/kokoro-ubuntu.sh
2 Make it Executable
chmod +x kokoro-ubuntu.sh
3 Run the Installer
The script installs Docker if needed and starts the CPU build of Kokoro FastAPI on port 8880, exposing an OpenAI-compatible text-to-speech endpoint.
sudo bash kokoro-ubuntu.sh
4 Generate Speech
Kokoro is an API — there's no web UI. Generate audio with a POST to the OpenAI-compatible speech endpoint:
curl -X POST http://<your-server-ip>:8880/v1/audio/speech
Ports Used
| Port | Purpose |
|---|---|
| 8880 | OpenAI-compatible /v1/audio/speech endpoint (host → container 8880) — no web UI |
| build | CPU build by default — runs well without a GPU |