homeassistant-tts-mcp
An MCP server that speaks text out loud
through your Home Assistant text-to-speech setup. It wraps the Home
Assistant tts.speak service so any MCP-capable AI client (Claude Desktop,
Claude Code, etc.) can talk through your speakers.
Tools
| Tool | What it does |
|---|---|
speak |
Speak a message on a media player via a TTS engine (tts.speak). |
list_media_players |
List media_player.* entities you can target. |
list_tts_engines |
List tts.* engines and their supported languages. |
check_connection |
Verify the URL + token work. |
Requirements
- A running Home Assistant instance with at least one TTS engine (Piper, Google Cloud, ElevenLabs, …) and a media player.
- A long-lived access token: Home Assistant → Profile → Security → Long-lived access tokens → Create token.
uv/uvxto run it (Python 3.10+).
Configuration
The server is configured entirely through environment variables:
| Variable | Required | Description |
|---|---|---|
HA_URL |
✅ | Base URL, e.g. http://homeassistant.local:8123 |
HA_TOKEN |
✅ | Long-lived access token |
HA_DEFAULT_MEDIA_PLAYER |
Fallback media player for speak |
|
HA_DEFAULT_TTS_ENTITY |
Fallback TTS engine, e.g. tts.piper |
|
HA_DEFAULT_VOICE |
Fallback voice, e.g. en_US-hfc_female-medium |
|
HA_DEFAULT_LANGUAGE |
Fallback language code, e.g. en |
|
HA_VERIFY_SSL |
false to skip TLS verification (self-signed certs) |
|
HA_TIMEOUT |
HTTP timeout in seconds (default 30) |
See .env.example.
Run it
Once published to PyPI:
uvx homeassistant-tts-mcp
The server speaks MCP over stdio, so you normally let your MCP client launch it. Example client config:
{
"mcpServers": {
"home-assistant-tts": {
"command": "uvx",
"args": ["homeassistant-tts-mcp"],
"env": {
"HA_URL": "http://homeassistant.local:8123",
"HA_TOKEN": "your-long-lived-access-token",
"HA_DEFAULT_MEDIA_PLAYER": "media_player.living_room",
"HA_DEFAULT_TTS_ENTITY": "tts.piper"
}
}
}
}
Then ask the assistant something like "Say 'dinner is ready' in the kitchen."
What speak sends
It maps directly onto the Home Assistant service call:
domain: tts
service: speak
entity_id: tts.piper # tts_entity_id
data:
media_player_entity_id: media_player.living_room
message: "Your spoken message goes here..."
options:
voice: en_US-hfc_female-medium # when voice is provided
Development
uv sync # create venv + install deps (incl. dev group)
uv run homeassistant-tts-mcp # run the server locally (needs HA_URL/HA_TOKEN)
uv run pytest # tests
uv run ruff check . # lint
Build & publish
uv build # produces dist/*.whl and *.tar.gz
uvx twine upload dist/* # publish to PyPI
# then it's runnable anywhere as: uvx homeassistant-tts-mcp
License
MIT — see LICENSE.
Metadata
Release files for homeassistant-tts-mcp 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| homeassistant_tts_mcp-0.1.1.tar.gz | 74.0 kB | Without provenance | Details for homeassistant_tts_mcp-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| homeassistant_tts_mcp-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for homeassistant_tts_mcp-0.1.1-py3-none-any.whl |
Total release size: 83.1 kB
Release files / homeassistant_tts_mcp-0.1.1.tar.gz
| Download URL | homeassistant_tts_mcp-0.1.1.tar.gz |
|---|---|
| Size | 74.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c452dc220c11d1766580b79701e3845b06164e4c08e4a5b562b6a55fddfb27d1
|
|
BLAKE2b-256 checksum How to use checksums |
d4ee3e01bc49a87c820f465983cd277ac00ef513acbf63c6c5f0b35cacd5d33a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / homeassistant_tts_mcp-0.1.1-py3-none-any.whl
| Download URL | homeassistant_tts_mcp-0.1.1-py3-none-any.whl |
|---|---|
| Size | 9.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
aeca035e354bbe69fe2443f30773964fbdae32690c2c01dd26d08019792dd2c5
|
|
BLAKE2b-256 checksum How to use checksums |
738ee5f78b9850e9d870ed060570115b98be2545bea3e48e18cf3637008baf06
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.21 {"installer":{"name":"uv","version":"0.9.21","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for homeassistant-tts-mcp 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.