<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
    <channel>
        <title>Integration on Smart Home? Sure — But Secure!</title>
        <link>https://smarthome-aber-sicher.de/en/tags/integration/</link>
        <description>Recent content in Integration on Smart Home? Sure — But Secure!</description>
        <generator>Hugo -- gohugo.io</generator>
        <language>en</language>
        <lastBuildDate>Sun, 21 Dec 2025 00:00:00 +0000</lastBuildDate><atom:link href="https://smarthome-aber-sicher.de/en/tags/integration/index.xml" rel="self" type="application/rss+xml" /><item>
        <title>Home Assistant A-Z: M is for MQTT – The Invisible Glue of Your Smart Home</title>
        <link>https://smarthome-aber-sicher.de/en/blog/2025/12/21/home-assistant-a-z-m-is-for-mqtt-the-invisible-glue-of-your-smart-home/</link>
        <pubDate>Sun, 21 Dec 2025 00:00:00 +0000</pubDate>
        
        <guid>https://smarthome-aber-sicher.de/en/blog/2025/12/21/home-assistant-a-z-m-is-for-mqtt-the-invisible-glue-of-your-smart-home/</guid>
        <description>&lt;img src="https://smarthome-aber-sicher.de/blog/2025/12/21/home-assistant-a-z-m-wie-mqtt-der-unsichtbare-klebstoff-f%C3%BCr-dein-smart-home/cover.png" alt="Featured image of post Home Assistant A-Z: M is for MQTT – The Invisible Glue of Your Smart Home" /&gt;&lt;h2 id=&#34;welcome-to-the-a-z-series-m-is-for-mqtt&#34;&gt;Welcome to the A-Z Series: M is for MQTT
&lt;/h2&gt;&lt;p&gt;In today&amp;rsquo;s episode of our &lt;strong&gt;Home Assistant A-Z Series&lt;/strong&gt;, we&amp;rsquo;re diving into a topic that works quietly in the background and yet is &lt;strong&gt;absolutely essential&lt;/strong&gt;: &lt;strong&gt;MQTT&lt;/strong&gt;! It&amp;rsquo;s the invisible glue that brings almost any device into your smart home. Without MQTT, my smart home would grind to a halt in many places – but why is that?&lt;/p&gt;
&lt;p&gt;Today I&amp;rsquo;ll explain in simple terms (promise: no complicated technical jargon!) what MQTT is, why it matters so much, and how I&amp;rsquo;ve integrated &lt;strong&gt;52 devices&lt;/strong&gt; with it in my Home Assistant setup.&lt;/p&gt;
&lt;div class=&#34;video-wrapper&#34;&gt;
    &lt;div class=&#34;video-placeholder&#34; onclick=&#34;loadIframe(this)&#34;&gt;
        &lt;img src=&#34;https://smarthome-aber-sicher.de/img/sas_youtube.png&#34; alt=&#34;YouTube Video&#34;&gt;
        &lt;div class=&#34;play-button&#34;&gt;&lt;/div&gt;
        &lt;div class=&#34;privacy-notice&#34;  style=&#34;color: var(--card-text-color-main);&#34;&gt;
            To load the video, please click the image. Please note that by doing so, data will be transmitted to YouTube.
        &lt;/div&gt;
    &lt;/div&gt;
&lt;/div&gt;
&lt;script&gt;
    function loadIframe(element) {
        var iframe = document.createElement(&#39;iframe&#39;);
        iframe.setAttribute(&#39;loading&#39;, &#39;lazy&#39;);
        iframe.setAttribute(&#39;src&#39;, &#39;https://www.youtube-nocookie.com/embed/cr5_LdP7BKM&#39;);
        iframe.setAttribute(&#39;allowfullscreen&#39;, &#39;&#39;);
        iframe.setAttribute(&#39;title&#39;, &#39;YouTube Video&#39;);
        element.parentNode.replaceChild(iframe, element);
    }
&lt;/script&gt;
&lt;style&gt;
    .video-placeholder {
        position: relative;
        cursor: pointer;
    }
    .video-placeholder img {
        width: 100%;
        height: auto;
    }
    .play-button {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 60px;
        height: 60px;
        background: url(&#39;/img/youtube_button.svg&#39;) no-repeat center center;
        background-size: contain;
    }
    .video-placeholder:hover .play-button {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 60px;
        height: 60px;
        background: url(&#39;/img/youtube_button_hover.svg&#39;) no-repeat center center;
        background-size: contain;
    }
    .privacy-notice {
        position: absolute;
        bottom: 50px;
        width: 100%;
        left: 50%;
        transform: translateX(-50%);
        background-color: rgba(0, 0, 0, 0.7);
        color: white;
        padding: 5px 10px;
        border-radius: 5px;
        font-size: 12px;
        text-align: center;
    }
&lt;/style&gt;

&lt;h2 id=&#34;what-is-mqtt-30-seconds-of-theory-jargon-free&#34;&gt;What Is MQTT? 30 Seconds of Theory, Jargon-Free
&lt;/h2&gt;&lt;p&gt;Let me explain MQTT so simply that &lt;strong&gt;anyone can understand it&lt;/strong&gt; – even if you&amp;rsquo;re not deeply technical.&lt;/p&gt;
&lt;h3 id=&#34;the-problem-without-mqtt&#34;&gt;The Problem Without MQTT
&lt;/h3&gt;&lt;p&gt;Normally, Home Assistant has to &lt;strong&gt;talk directly to every device&lt;/strong&gt;. That means:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Home Assistant needs to know &lt;strong&gt;how to control the device&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;What &lt;strong&gt;data&lt;/strong&gt; the device sends&lt;/li&gt;
&lt;li&gt;In what &lt;strong&gt;units&lt;/strong&gt; the data arrives&lt;/li&gt;
&lt;li&gt;What &lt;strong&gt;interface&lt;/strong&gt; the device uses&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;For &lt;strong&gt;every single device&lt;/strong&gt;, Home Assistant needs its own dedicated integration. That&amp;rsquo;s a lot of work and limits the number of supported devices.&lt;/p&gt;
&lt;h3 id=&#34;the-solution-mqtt-as-a-middleman&#34;&gt;The Solution: MQTT as a Middleman
&lt;/h3&gt;&lt;p&gt;&lt;strong&gt;MQTT steps in between&lt;/strong&gt; and simplifies everything dramatically:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Home Assistant&lt;/strong&gt; only needs to know how to read from an &lt;strong&gt;MQTT server&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;The device&lt;/strong&gt; only needs to know how to post its data to &lt;strong&gt;MQTT&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;The &lt;strong&gt;MQTT Broker&lt;/strong&gt; (server) mediates between the two&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;the-brilliant-advantage&#34;&gt;The Brilliant Advantage
&lt;/h3&gt;&lt;p&gt;This has a &lt;strong&gt;huge advantage&lt;/strong&gt;:&lt;/p&gt;
&lt;p&gt;✅ &lt;strong&gt;The device&lt;/strong&gt; can support MQTT and doesn&amp;rsquo;t care whether you&amp;rsquo;re using Home Assistant, OpenHAB, or any other smart home solution&lt;/p&gt;
&lt;p&gt;✅ &lt;strong&gt;Home Assistant&lt;/strong&gt; doesn&amp;rsquo;t care which device you have – as long as it &lt;strong&gt;speaks MQTT&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;MQTT is therefore a supremely universal solution&lt;/strong&gt; for integrating as many devices as possible into Home Assistant, &lt;strong&gt;without Home Assistant needing to explicitly support each device&lt;/strong&gt;!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video, I explain this even more clearly with a diagram!&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id=&#34;a-live-look-52-devices-via-mqtt-in-my-smart-home&#34;&gt;A Live Look: 52 Devices via MQTT in My Smart Home
&lt;/h2&gt;&lt;p&gt;Enough theory! Let&amp;rsquo;s look at a &lt;strong&gt;real smart home&lt;/strong&gt; and see everything I&amp;rsquo;ve integrated with MQTT.&lt;/p&gt;
&lt;p&gt;In my &lt;strong&gt;MQTT integration&lt;/strong&gt; in Home Assistant, I can see: &lt;strong&gt;52 devices&lt;/strong&gt; connected via MQTT. That&amp;rsquo;s more than half of all my devices! Without MQTT, my smart home would be capable of considerably less.&lt;/p&gt;
&lt;p&gt;Let&amp;rsquo;s look at some &lt;strong&gt;concrete examples&lt;/strong&gt;:&lt;/p&gt;
&lt;h3 id=&#34;aqara-motion-sensors-via-zigbee2mqtt&#34;&gt;Aqara Motion Sensors via Zigbee2MQTT
&lt;/h3&gt;&lt;p&gt;I have several &lt;strong&gt;Aqara motion sensors&lt;/strong&gt; distributed throughout my smart home – in the hallway, bathroom, storage room, and other areas.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;How are they integrated?&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The sensors speak &lt;strong&gt;Zigbee&lt;/strong&gt; (a wireless protocol)&lt;/li&gt;
&lt;li&gt;I use &lt;strong&gt;Zigbee2MQTT&lt;/strong&gt; – the universal gateway for Zigbee devices&lt;/li&gt;
&lt;li&gt;Zigbee2MQTT translates Zigbee signals into MQTT messages&lt;/li&gt;
&lt;li&gt;Home Assistant reads these MQTT messages&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The brilliant part: &lt;strong&gt;Zigbee2MQTT supports hundreds of different Zigbee devices&lt;/strong&gt; from a wide variety of manufacturers. Set it up once, and everything works through the same pipeline!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video you can see the motion sensors live in the dashboard!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;philips-hue-lights-via-zigbee2mqtt&#34;&gt;Philips Hue Lights via Zigbee2MQTT
&lt;/h3&gt;&lt;p&gt;My &lt;strong&gt;Philips Hue lights&lt;/strong&gt; also run via MQTT – likewise through &lt;strong&gt;Zigbee2MQTT&lt;/strong&gt;!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why not the official Philips Hue Bridge?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Good question! The Hue Bridge would certainly work too, but:&lt;/p&gt;
&lt;p&gt;✅ &lt;strong&gt;With Zigbee2MQTT I skip the need for an extra bridge&lt;/strong&gt;
✅ &lt;strong&gt;Everything runs through the same infrastructure&lt;/strong&gt; (one Zigbee stick)
✅ &lt;strong&gt;Completely local&lt;/strong&gt; – no Philips cloud required
✅ &lt;strong&gt;Cheaper&lt;/strong&gt; (no expensive Hue Bridge needed)&lt;/p&gt;
&lt;p&gt;Hue lights &lt;strong&gt;also speak Zigbee&lt;/strong&gt;, so they can communicate with Zigbee2MQTT just as easily as the Aqara sensors!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Where I use Hue lights:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Bedroom (for the wake-up light)&lt;/li&gt;
&lt;li&gt;Terrace (for evening lighting)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;In the video I&amp;rsquo;ll show you what the Hue lights look like in the MQTT dashboard!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;sonoff-devices-with-tasmota-firmware&#34;&gt;Sonoff Devices with TASMOTA Firmware
&lt;/h3&gt;&lt;p&gt;Another great example: &lt;strong&gt;Sonoff devices&lt;/strong&gt;. These are smart relays and sensors – similar to Shelly modules.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;My configuration:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve flashed most of my Sonoff devices with &lt;strong&gt;TASMOTA firmware&lt;/strong&gt;. This is an &lt;strong&gt;open-source, alternative firmware&lt;/strong&gt; that:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;✅ Works completely &lt;strong&gt;locally&lt;/strong&gt; (no cloud)&lt;/li&gt;
&lt;li&gt;✅ &lt;strong&gt;Natively supports MQTT&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;✅ Is far &lt;strong&gt;more flexible&lt;/strong&gt; than the stock firmware&lt;/li&gt;
&lt;li&gt;✅ Is &lt;strong&gt;more secure&lt;/strong&gt; (open source, no backdoors)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The Sonoff devices communicate via &lt;strong&gt;Wi-Fi&lt;/strong&gt; (not Zigbee!) and send their data directly to the MQTT Broker.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Examples in my setup:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Smart plugs&lt;/li&gt;
&lt;li&gt;Relays for light control&lt;/li&gt;
&lt;li&gt;Temperature sensors&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;In the video I go into more detail on TASMOTA and show you what the devices look like!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;xiaomi-light-sensors-for-automations&#34;&gt;Xiaomi Light Sensors for Automations
&lt;/h3&gt;&lt;p&gt;I have two &lt;strong&gt;Xiaomi light sensors&lt;/strong&gt; mounted on the outside of the building. They continuously measure &lt;strong&gt;brightness&lt;/strong&gt; and help me with various automations.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What I use them for:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Automatic lighting&lt;/strong&gt; (e.g., terrace lights at dusk)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Blind control&lt;/strong&gt; (automatically closing when the sun is intense)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Energy management&lt;/strong&gt; (cloud cover = lower PV output)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;These sensors also speak &lt;strong&gt;Zigbee&lt;/strong&gt; and run via &lt;strong&gt;Zigbee2MQTT&lt;/strong&gt; through MQTT into Home Assistant.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video I show you the live sensor readings!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;wallbox-via-evcc&#34;&gt;Wallbox via EVCC
&lt;/h3&gt;&lt;p&gt;A particularly &lt;strong&gt;cool example&lt;/strong&gt;: my &lt;strong&gt;wallbox&lt;/strong&gt; for the EV is also integrated via MQTT!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;How does that work?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;I use &lt;strong&gt;EVCC&lt;/strong&gt; (Electric Vehicle Charge Controller) – intelligent software for managing the wallbox. EVCC can:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;PV surplus charging&lt;/strong&gt; (only charge when the solar system produces enough power)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Use dynamic electricity prices&lt;/strong&gt; (charge when power is cheap)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Monitor all values&lt;/strong&gt; (charging power, battery level, costs)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;EVCC publishes all these values to MQTT&lt;/strong&gt;, making them available in Home Assistant.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What I get via MQTT:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Current charging power&lt;/strong&gt; (in kW)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Total energy meter&lt;/strong&gt; (total amount charged)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Current charging price&lt;/strong&gt; (for dynamic tariffs)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Grid price&lt;/strong&gt; and &lt;strong&gt;electricity rates&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;EV state of charge&lt;/strong&gt; (in %)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;All this data can be used in &lt;strong&gt;automations&lt;/strong&gt; or displayed on &lt;strong&gt;dashboards&lt;/strong&gt;!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;More on EVCC is available in my dedicated video – link in the video and description above!&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video I show you the wallbox entities live in the MQTT dashboard!&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id=&#34;why-mqtt-is-so-important&#34;&gt;Why MQTT Is So Important
&lt;/h2&gt;&lt;p&gt;After all these examples, it&amp;rsquo;s clear: &lt;strong&gt;MQTT is the backbone of my smart home!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;the-advantages-at-a-glance&#34;&gt;The Advantages at a Glance
&lt;/h3&gt;&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Universal:&lt;/strong&gt; Almost any device can speak MQTT&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Vendor-independent:&lt;/strong&gt; Whether Aqara, Philips, Sonoff, or Xiaomi – they all use MQTT&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Protocol-agnostic:&lt;/strong&gt; Zigbee, Wi-Fi, even Ethernet – everything ends up at MQTT&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Future-proof:&lt;/strong&gt; New device? If it speaks MQTT, it works&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Local:&lt;/strong&gt; No cloud required, everything stays on your own network&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;strong&gt;In the video I go even deeper into these advantages!&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id=&#34;installation-how-to-get-mqtt-into-home-assistant&#34;&gt;Installation: How to Get MQTT Into Home Assistant
&lt;/h2&gt;&lt;p&gt;Convinced and ready to use MQTT? No problem – the installation is &lt;strong&gt;surprisingly easy&lt;/strong&gt;!&lt;/p&gt;
&lt;h3 id=&#34;option-1-home-assistant-os-recommended-for-beginners&#34;&gt;Option 1: Home Assistant OS (recommended for beginners)
&lt;/h3&gt;&lt;p&gt;If you&amp;rsquo;re running &lt;strong&gt;Home Assistant OS&lt;/strong&gt;, MQTT is just one click away:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 1:&lt;/strong&gt; Go to &lt;strong&gt;Settings → Add-ons&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 2:&lt;/strong&gt; Search for &lt;strong&gt;&amp;ldquo;Mosquitto broker&amp;rdquo;&lt;/strong&gt; (this is the MQTT server)&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 3:&lt;/strong&gt; Install the add-on and start it&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Step 4:&lt;/strong&gt; Home Assistant automatically detects the Broker and suggests the integration&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;That&amp;rsquo;s it!&lt;/strong&gt; No complex configuration needed. The Broker is running and ready to use immediately.&lt;/p&gt;
&lt;h3 id=&#34;option-2-home-assistant-core--docker&#34;&gt;Option 2: Home Assistant Core / Docker
&lt;/h3&gt;&lt;p&gt;If you run &lt;strong&gt;Home Assistant Core&lt;/strong&gt; and manage everything via Docker, you can start the &lt;strong&gt;Mosquitto Broker as a separate container&lt;/strong&gt;:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Docker Compose example:&lt;/strong&gt;&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;div class=&#34;chroma&#34;&gt;
&lt;table class=&#34;lntable&#34;&gt;&lt;tr&gt;&lt;td class=&#34;lntd&#34;&gt;
&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code&gt;&lt;span class=&#34;lnt&#34;&gt;1
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;2
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;3
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;4
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;5
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;6
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;7
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;
&lt;td class=&#34;lntd&#34;&gt;
&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-yaml&#34; data-lang=&#34;yaml&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;nt&#34;&gt;mosquitto&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;  &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;image&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt; &lt;/span&gt;&lt;span class=&#34;l&#34;&gt;eclipse-mosquitto:latest&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;  &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;ports&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;- &lt;span class=&#34;s2&#34;&gt;&amp;#34;1883:1883&amp;#34;&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;  &lt;/span&gt;&lt;span class=&#34;nt&#34;&gt;volumes&lt;/span&gt;&lt;span class=&#34;p&#34;&gt;:&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;- &lt;span class=&#34;l&#34;&gt;./mosquitto/config:/mosquitto/config&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;&lt;span class=&#34;w&#34;&gt;    &lt;/span&gt;- &lt;span class=&#34;l&#34;&gt;./mosquitto/data:/mosquitto/data&lt;/span&gt;&lt;span class=&#34;w&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;Then add the &lt;strong&gt;MQTT integration&lt;/strong&gt; in Home Assistant and provide the IP address and port (1883) of the Mosquitto container.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video I show you both installation methods!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;configuration-almost-none-required&#34;&gt;Configuration: Almost None Required!
&lt;/h3&gt;&lt;p&gt;The &lt;strong&gt;beauty of MQTT&lt;/strong&gt;: it requires &lt;strong&gt;almost no configuration&lt;/strong&gt;!&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The default port (1883) works out of the box&lt;/li&gt;
&lt;li&gt;No complex settings&lt;/li&gt;
&lt;li&gt;Ready to use immediately&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Of course, for added security you can also:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Set up a &lt;strong&gt;username and password&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Enable &lt;strong&gt;TLS encryption&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;Configure &lt;strong&gt;Access Control Lists&lt;/strong&gt; (ACLs)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;But for &lt;strong&gt;getting started&lt;/strong&gt;, the default configuration is perfectly sufficient!&lt;/p&gt;
&lt;h2 id=&#34;connecting-devices-to-mqtt&#34;&gt;Connecting Devices to MQTT
&lt;/h2&gt;&lt;p&gt;You now have an &lt;strong&gt;MQTT Broker&lt;/strong&gt; running – but how do devices connect to it?&lt;/p&gt;
&lt;h3 id=&#34;zigbee-devices-zigbee2mqtt&#34;&gt;Zigbee Devices: Zigbee2MQTT
&lt;/h3&gt;&lt;p&gt;For &lt;strong&gt;all Zigbee devices&lt;/strong&gt;, I recommend &lt;strong&gt;Zigbee2MQTT&lt;/strong&gt;:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What you need:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;A &lt;strong&gt;Zigbee USB stick&lt;/strong&gt; (e.g., ConBee II, Sonoff Zigbee 3.0)&lt;/li&gt;
&lt;li&gt;The &lt;strong&gt;Zigbee2MQTT software&lt;/strong&gt; (as an add-on or Docker container)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Setup:&lt;/strong&gt;&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Plug in the Zigbee stick&lt;/li&gt;
&lt;li&gt;Install Zigbee2MQTT&lt;/li&gt;
&lt;li&gt;Enter the MQTT Broker details (usually done automatically)&lt;/li&gt;
&lt;li&gt;Pair devices (put them into pairing mode)&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;&lt;strong&gt;Done!&lt;/strong&gt; All Zigbee devices appear automatically in Home Assistant.&lt;/p&gt;
&lt;h3 id=&#34;wi-fi-devices-native-mqtt-support-or-tasmota&#34;&gt;Wi-Fi Devices: Native MQTT Support or TASMOTA
&lt;/h3&gt;&lt;p&gt;&lt;strong&gt;Some devices&lt;/strong&gt; (e.g., Shelly, ESPHome devices) &lt;strong&gt;natively support MQTT&lt;/strong&gt;. Simply enter the MQTT Broker IP in their settings – done!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Other devices&lt;/strong&gt; (e.g., Sonoff) can be &lt;strong&gt;flashed with TASMOTA&lt;/strong&gt; and then have MQTT enabled.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video I walk through concrete examples!&lt;/strong&gt;&lt;/p&gt;
&lt;h3 id=&#34;software-integrations-evcc-and-others&#34;&gt;Software Integrations: EVCC and Others
&lt;/h3&gt;&lt;p&gt;Many &lt;strong&gt;software tools&lt;/strong&gt; like EVCC can publish their data to MQTT. In the respective configuration, you enable MQTT and provide the Broker details – and the data flows straight into Home Assistant!&lt;/p&gt;
&lt;h2 id=&#34;creative-use-cases-for-mqtt&#34;&gt;Creative Use Cases for MQTT
&lt;/h2&gt;&lt;p&gt;Beyond plain device data, you can also use MQTT for &lt;strong&gt;creative purposes&lt;/strong&gt;:&lt;/p&gt;
&lt;h3 id=&#34;build-your-own-sensors&#34;&gt;Build Your Own Sensors
&lt;/h3&gt;&lt;p&gt;With &lt;strong&gt;ESPHome or TASMOTA&lt;/strong&gt; you can build custom sensors and integrate them via MQTT:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Temperature and humidity sensors&lt;/strong&gt; in the garden&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Water level sensors&lt;/strong&gt; for plants or cisterns&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Door contacts&lt;/strong&gt; in unusual locations&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;PIR sensors&lt;/strong&gt; for motion detection&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;exchange-data-between-systems&#34;&gt;Exchange Data Between Systems
&lt;/h3&gt;&lt;p&gt;MQTT is perfect for &lt;strong&gt;sharing data between different systems&lt;/strong&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Home Assistant → Node-RED → MQTT&lt;/li&gt;
&lt;li&gt;MQTT → Grafana (for beautiful dashboards)&lt;/li&gt;
&lt;li&gt;MQTT → InfluxDB (for long-term data analysis)&lt;/li&gt;
&lt;/ul&gt;
&lt;h3 id=&#34;trigger-external-automations&#34;&gt;Trigger External Automations
&lt;/h3&gt;&lt;p&gt;You can &lt;strong&gt;trigger external tools&lt;/strong&gt; via MQTT messages:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Start the &lt;strong&gt;3D printer&lt;/strong&gt; when the solar system has enough surplus&lt;/li&gt;
&lt;li&gt;Activate the &lt;strong&gt;irrigation system&lt;/strong&gt; when soil moisture is low&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Arm security systems&lt;/strong&gt; based on presence&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;The possibilities are endless!&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id=&#34;pitfalls-and-tips&#34;&gt;Pitfalls and Tips
&lt;/h2&gt;&lt;p&gt;To wrap up, here are a few &lt;strong&gt;important tips&lt;/strong&gt; from my own experience:&lt;/p&gt;
&lt;h3 id=&#34;tip-1-plan-your-topic-structure-early&#34;&gt;Tip 1: Plan Your Topic Structure Early
&lt;/h3&gt;&lt;p&gt;MQTT uses &lt;strong&gt;Topics&lt;/strong&gt; for organization. Think through a &lt;strong&gt;sensible hierarchy&lt;/strong&gt; from the start:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;div class=&#34;chroma&#34;&gt;
&lt;table class=&#34;lntable&#34;&gt;&lt;tr&gt;&lt;td class=&#34;lntd&#34;&gt;
&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code&gt;&lt;span class=&#34;lnt&#34;&gt;1
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;2
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;3
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;
&lt;td class=&#34;lntd&#34;&gt;
&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-fallback&#34; data-lang=&#34;fallback&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;home/living-room/temperature
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;home/living-room/humidity
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;home/bedroom/temperature
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;Not:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;div class=&#34;chroma&#34;&gt;
&lt;table class=&#34;lntable&#34;&gt;&lt;tr&gt;&lt;td class=&#34;lntd&#34;&gt;
&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code&gt;&lt;span class=&#34;lnt&#34;&gt;1
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;2
&lt;/span&gt;&lt;span class=&#34;lnt&#34;&gt;3
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;
&lt;td class=&#34;lntd&#34;&gt;
&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-fallback&#34; data-lang=&#34;fallback&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;temp_living-room
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;humidity_living-room
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;temperature_bedroom
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;
&lt;/div&gt;
&lt;/div&gt;&lt;p&gt;&lt;strong&gt;A clear structure&lt;/strong&gt; will save you a lot of headaches later!&lt;/p&gt;
&lt;h3 id=&#34;tip-2-use-retained-messages&#34;&gt;Tip 2: Use Retained Messages
&lt;/h3&gt;&lt;p&gt;For &lt;strong&gt;status values&lt;/strong&gt;, you should enable &lt;strong&gt;Retained Messages&lt;/strong&gt;. This way the Broker stores the last known value – even if a client restarts.&lt;/p&gt;
&lt;h3 id=&#34;tip-3-understand-quality-of-service-qos&#34;&gt;Tip 3: Understand Quality of Service (QoS)
&lt;/h3&gt;&lt;p&gt;MQTT defines three &lt;strong&gt;QoS levels&lt;/strong&gt;:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;QoS 0:&lt;/strong&gt; Fire and forget (fast, but unreliable)&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;QoS 1:&lt;/strong&gt; Delivered at least once&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;QoS 2:&lt;/strong&gt; Delivered exactly once&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;For smart home purposes, &lt;strong&gt;QoS 1&lt;/strong&gt; is usually sufficient.&lt;/p&gt;
&lt;h3 id=&#34;tip-4-use-discovery&#34;&gt;Tip 4: Use Discovery
&lt;/h3&gt;&lt;p&gt;Many tools (e.g., Zigbee2MQTT, TASMOTA) support &lt;strong&gt;MQTT Discovery&lt;/strong&gt;. This means devices &lt;strong&gt;register themselves automatically&lt;/strong&gt; with Home Assistant – no manual configuration needed!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;In the video I go into these tips in more detail!&lt;/strong&gt;&lt;/p&gt;
&lt;h2 id=&#34;conclusion-mqtt-is-indispensable&#34;&gt;Conclusion: MQTT Is Indispensable
&lt;/h2&gt;&lt;p&gt;After all of this, it&amp;rsquo;s clear: &lt;strong&gt;MQTT is absolutely indispensable for my smart home!&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What I wouldn&amp;rsquo;t have without MQTT:&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;52 fewer devices&lt;/li&gt;
&lt;li&gt;No Zigbee devices&lt;/li&gt;
&lt;li&gt;No flexible wallbox integration&lt;/li&gt;
&lt;li&gt;Far fewer options for custom projects&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;MQTT makes a smart home flexible, open, and future-proof.&lt;/strong&gt; It&amp;rsquo;s one of the reasons I value Home Assistant so highly!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Make sure to watch the video&lt;/strong&gt; – there you&amp;rsquo;ll see everything in action live!&lt;/p&gt;
&lt;h2 id=&#34;your-experiences&#34;&gt;Your Experiences?
&lt;/h2&gt;&lt;p&gt;&lt;strong&gt;What do you integrate with MQTT?&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Let me know in the comments:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Which devices do you use over MQTT?&lt;/li&gt;
&lt;li&gt;Do you have creative use cases?&lt;/li&gt;
&lt;li&gt;Are you using Zigbee2MQTT or other gateways?&lt;/li&gt;
&lt;li&gt;What questions do you have about MQTT?&lt;/li&gt;
&lt;/ul&gt;
&lt;h2 id=&#34;further-reading-and-videos&#34;&gt;Further Reading and Videos
&lt;/h2&gt;&lt;p&gt;If you&amp;rsquo;re interested in MQTT and related topics:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;&lt;a class=&#34;link&#34; href=&#34;https://smarthome-aber-sicher.de/post/evcc-ueberblick/&#34; &gt;EVCC: Smart EV Charging&lt;/a&gt;&lt;/strong&gt; – How I connect the wallbox via MQTT&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a class=&#34;link&#34; href=&#34;https://smarthome-aber-sicher.de/blog/2025/11/09/home-assistant-a-z-e-wie-entitaeten-das-herzst%c3%bcck-deines-smart-homes/&#34; &gt;Understanding Entities&lt;/a&gt;&lt;/strong&gt; – How MQTT devices appear as entities&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a class=&#34;link&#34; href=&#34;https://smarthome-aber-sicher.de/post/geschirrspueler/&#34; &gt;Making Your Dishwasher Smart&lt;/a&gt;&lt;/strong&gt; – With MQTT-capable smart plugs&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;Find the complete A-Z Series here:&lt;/strong&gt; &lt;a class=&#34;link&#34; href=&#34;https://smarthome-aber-sicher.de/tags/a-z-serie/&#34; &gt;Home Assistant A-Z Overview&lt;/a&gt;&lt;/p&gt;
&lt;nav class=&#34;ha-az-nav&#34; aria-label=&#34;Home Assistant A-Z Navigation&#34;&gt;
  &lt;div class=&#34;ha-az-nav-label&#34;&gt;📚 Home Assistant A–Z · Teil 13 von 15&lt;/div&gt;
  &lt;div class=&#34;ha-az-nav-inner&#34;&gt;&lt;a href=&#34;https://smarthome-aber-sicher.de/post/ha-az/12-licht/&#34; class=&#34;ha-az-nav-btn ha-az-nav-prev&#34;&gt;← L · Licht&lt;/a&gt;&lt;a href=&#34;https://smarthome-aber-sicher.de/post/ha-az/14-nachtmodus/&#34; class=&#34;ha-az-nav-btn ha-az-nav-next&#34;&gt;N · Nachtmodus →&lt;/a&gt;&lt;/div&gt;
&lt;/nav&gt;
</description>
        </item>
        
    </channel>
</rss>
