Home Assistant–based system that uses Music Assistant and Snapcast clients distributed around the house. My phone’s presence determines which room I’m in, and audio is dynamically routed to the appropriate Snapcast client so music follows, without manual switching.
Griff’s Presence-Aware Audio
Whole-home synced music using Home Assistant + Music Assistant + Snapcast
This setup is my “whole-home audio backbone”: synced music across multiple speaker zones, with the option to later add presence logic so audio can follow me around the house.
At a high level, the system is:
Home Assistant (HA) → Music Assistant add-on → Snapcast server + multiple Snapcast clients (one per speaker/zone)
Core Components
1) Home Assistant (HA)
HA is the orchestration layer. It’s the system that hosts integrations, automations, and the overall “brains” of the house.
2) Music Assistant (add-on inside HA)
Music Assistant runs as an add-on and becomes the control plane for playback: sources, queues, grouping, and routing audio outputs. This is where you configure your Spotify plugin, Tidal, Youtube music etc. There are several source plugins available
Think of it as:
-
HA provides the platform + automation
-
Music Assistant provides the music “engine” and speaker/group management
-
Snapcast clients are the “nodes”
3) Snapcast (server + clients)
Snapcast is what makes the “perfect sync” possible. It’s designed to play the same audio stream on multiple clients while staying time-aligned.
-
Snapcast Server: publishes the audio stream(s)
-
Snapcast Clients: receive the stream and output audio on each endpoint device
Clients can be almost anything:
-
Raspberry Pi (my go-to)
-
thin clients / mini PCs
-
Linux boxes
-
some Android devices (Snapcast client app)
-
basically anything that can run a Snapcast client and output audio
-
There is an esp32 variant called Esparagus as well (trying to get it to work now)
I use $10 Raspberry Pi Zero W units as Snapcast clients placed around the house. They’re inexpensive, low power, and “good enough” for endpoint audio. Any model Pi works, and you don’t need a Pi at all if you’ve got other small Linux devices. However you need to figure out how it labels its audio outs.
You can even participate from your phone by running a Snapcast client app as it is handy for testing, or for temporarily adding a “zone.” Make your guests walk around with music in their pocket for a fun party trick
What you get once the basics are running
With HA + Music Assistant + Snapcast clients, you get:
-
Multi-room playback
-
Grouped speakers (zones)
-
Tight synchronization between rooms
-
Central control through Music Assistant (and automations through HA)
This is the foundation that makes “presence-aware audio” possible later — but even without presence logic, it’s already a very usable whole-home system.
Important practical detail: manual client synchronization
Snapcast is good, but real homes have real latency differences:
-
different DACs / sound cards
-
different speakers or amps
-
different buffering behavior
-
different Wi-Fi conditions
So each client often needs a manual timing offset to make everything feel perfectly aligned. This isn’t an easy process with moving devices (actually kinda impossible), but fixed speakers its a set and forget situation, screenshot it, the forget problem is real. Also unifying your node hardware types are a good idea. Client + DAC. The Amp is analog and generally inconsequential.
In practice, you adjust each client with a timing offset (in milliseconds). Snapcast supports shifting playback earlier or later per client. It’s normal to have to compensate by hundreds of ms, and more than a second around at 1000 feet away.
Once it’s dialed in, it stays stable and the result is the “walk through the house and it still sounds like one song” effect.
Raspberry Pi Zero W reliability notes (learned the hard way)
The “hard part” isn’t Snapcast itself, it’s keeping a bunch of tiny clients reliable over months.
Two tips that matter a lot:
1) Find one SD card image that’s rock solid
Once you have a Pi client that:
-
boots cleanly every time
-
joins Wi-Fi consistently
-
runs the Snapcast client reliably
/usr/bin/snapclient --logsink=system --player alsa --host --device plughw:0,0 --logfilter=debug
2) Write-protect and clone it
Once you have a proven image, it’s highly recommended to:
-
write-protect that SD card (or otherwise treat it as your master)
-
clone it for your other clients, just change the name and the outputs as needed (ALSA+ plughw)
Why: many reliability problems on Pi Zeros are SD-card related (wear, corruption, brownouts, etc.). A stable “golden image” makes scaling easier, and it makes recovery trivial if a client ever misbehaves, blow it away and reimage.
My apologies for not being able to include links in posts. A quick search will find this
Thanks for this very detailed write up. I. curious if you’ve been down the video path yet, looking for the same results of one source that I can sync to multiple tvs, controlled from one “remote” or tablet running HA
I’ve been looking for the same thing and haven’t really found a clean open-source solution yet.
The tech itself does exist. 802.1AS/PTP, AVB/TSN, and SMPTE 2110 are all designed to keep video and audio in sync across multiple endpoints. In reality though, that stuff mostly lives in broadcast studios and commercial AV systems.
There are open-source pieces you can play with, like linuxptp, NMOS, and OpenVisualCloud, but nothing that feels like a “Snapcast for video” where you install it, point it at a source, and have multiple TVs stay perfectly in sync from one UI like Home Assistant.
My guess is OpenVisualCloud or IPMX is where this eventually lands, but right now it’s more a collection of building blocks than a finished product. Audio got solved first because buffering is forgiving. Video is a lot less forgiving, which makes it much harder.
When I bought my house I decided to go the central closet route and have a whole home 6 zone amplifier and matrix video switcher. From my central equipment closet I ran speaker wires to in ceiling speakers and Cat6 to wall jacks for video. Synchronization is achieved by being a single device with speaker wire and video runs to each room, a star configuration.
It certainly isn’t the cheapest solution or easiest to install, but once installed it has been extremely reliable. I mostly leverage the whole house audio vs video as it is just my wife and myself.
My primary audio/music source is my linux server which hosts HomeAsisstant and runs MusicAssistant. It is one of the inputs to this whole house amplifier, which I control through HomeAssistant via the serial port. The whole house amplifier I am using is linked below. I never installed the in wall controls because I can do it all from HomeAssistant. In some rooms I have wall mounted tablets running the HomeAssistant app. I can then control all aspects of the room (music, sound levels, lighting, etc) from that tablet.
You could certainly use presence detection to automatically turn on/off speaker zones based on location with this configuration as well.
Thanks for the info. I was wondering if something like this combined with @Griff setup would work, and that sounds like what you are running.
Yes, something like that is what I am running. I have an older video matrix switcher which is no longer available. I can send any video input (Cable TV Box, AppleTV/FireTV, BluRayPlayer, PC Output, etc) simultaneously or separately to any room.
Are you able to use the tablets and HA to control the video streams as well?
No, I am not currently able to control the matrix video switcher via HA. The older matrix video switcher I am using does not have external control via serial or network control, it is only controlled via IR. I have programmable universal remotes in each room which have activity buttons to “Watch Cable”, “Watch Streaming”, etc. The universal remote will send the appropriate IR commands to all devices. I have an IR receiver in each room which relays the IR back to the central closet for controlling any equipment there. The problem with that solution is that equipment state can get out of sync since there is no feedback as to current configuration.
I am sure there are HomeAssistant enabled IR receivers/emitters that I could use to control the equipment, but I haven’t felt the need to go there yet.
A more recent Video Matrix switcher would most likely have the ability to control the switcher programmatically over Serial or network, and therefore get you good HA control. It looks like the one you linked does have that ability.
I have one location in the house (before I bought it) that has 3 sets of house speaker inputs. So instead of using three Pis. I will use one and three dacs ala this RPi 5 Quad Stereo Sound with PCM5102A – Simple DIY Electronic Music Projects