---
title: "MQTT"
description: "MQTT is a built-in integration for Home Assistant. It has 274k installs sharing analytics and works locally."
canonical: "https://vulpo.app/integrations/core/mqtt"
url: "https://vulpo.app/integrations/core/mqtt.md"
last-updated: "2026-10-22"
version: "1.4"
---

# MQTT

> MQTT is a built-in integration for Home Assistant. It has 274k installs sharing analytics and works locally.

MQTT is a built-in integration that connects Home Assistant to an MQTT broker and works locally. It supports many entity platforms, including sensors, switches, lights-style controls such as fans and covers, climate, cameras, locks and vacuums. New devices can show up through automatic discovery, which uses a configurable topic prefix. Birth and will messages can be set with their own topic, payload, quality of service and retain options. The connection supports username and password login, custom CA certificates, client certificates, a choice of transport and a keep alive interval. Actions publish a message to a topic, export messages from a topic to a file, and reload entities defined in YAML. It is set up in the UI, and its connection settings can be changed later.

Automatic summary of Home Assistant's source code. Something wrong? [Get in touch](https://vulpo.app/contact)

[Open in My Home Assistant](https://my.home-assistant.io/redirect/config_flow_start/?domain=mqtt)

## Supports

- **Works locally**: Talks to your devices on your own network. No vendor cloud in between.
- **Set up in the UI**: Add it in Settings, Devices and services. Nothing to download.
- **Device triggers**: Its devices can start automations directly.
- **Adds new devices**: New devices show up without setting it up again.
- **Change settings later**: Its connection settings can change without removing it.
- **Platinum quality**: Home Assistant's own rating of its code and setup experience.
- **Updated with Home Assistant**: Ships and updates with every Home Assistant release.

## Setting it up

It is added under Settings, Devices and services, with Add integration.

### Broker

- **Broker**: The hostname or IP address of your MQTT broker.
- **Password**: The password to log in to your MQTT broker.
- **Port**: The port your MQTT broker listens to. For example 1883.
- **MQTT protocol**: The MQTT protocol version that is used. Note that Home Assistant will silently change to version 5 if your broker supports it.
- **Username**: The username to log in to your MQTT broker.
- **Upload custom CA certificate file**: The custom CA certificate file to validate your MQTT broker's certificate.
- **Upload client certificate file**: The client certificate to authenticate against your MQTT broker.
- **Client ID (leave empty for a randomly generated one)**: The unique ID to identify the Home Assistant MQTT API as MQTT client. It is recommended to leave this option blank.
- **Upload private key file**: The private key file that belongs to your client certificate.
- **Password**: The password for the private key file (if set).
- **The time between sending keep alive messages**: A value less than 90 seconds is advised. Defaults to 60 seconds.
- **Broker certificate validation**: When already set to Custom, a custom CA validation certificate is configured. Select Auto for automatic CA validation, or upload a custom CA certificate, to allow validating your MQTT broker's certificate.
- **Use a client certificate**: When already selected, client certificate authentication is enabled. Upload a client certificate and key to enable.
- **Ignore broker certificate validation**: Option to ignore validation of your MQTT broker's certificate.
- **MQTT transport**: The transport to be used for the connection to your MQTT broker.

### Re-authentication required with the MQTT broker

- **Password**: The password to log in to your MQTT broker.
- **Username**: The username to log in to your MQTT broker.

### After setup

- **Enable birth message**: When set, Home Assistant will publish an online message to your MQTT broker when MQTT is ready.
- **Birth message payload**: The "birth" message that is published when MQTT is ready and connected.
- **Birth message QoS**: The quality of service of the "birth" message that is published when MQTT is ready and connected
- **Birth message retain**: When set, Home Assistant will retain the "birth" message published to your MQTT broker.
- **Birth message topic**: The MQTT topic where Home Assistant will publish a "birth" message.
- **Enable discovery**: Option to enable MQTT automatic discovery.
- **Discovery prefix**: The prefix of configuration topics the MQTT integration will subscribe to.
- **Discovery QoS**: The quality of service for discovery subscriptions to your MQTT broker.
- **Enable will message**: When set, Home Assistant will ask your broker to publish a "will" message when MQTT is stopped or when it loses the connection to your broker.
- **Will message payload**: The message your MQTT broker "will" publish when the MQTT integration is stopped or when the connection is lost.
- **Will message QoS**: The quality of service of the "will" message that is published by your MQTT broker.
- **Will message retain**: When set, your MQTT broker will retain the "will" message.
- **Will message topic**: The MQTT topic your MQTT broker will publish a "will" message to.

Texts from Home Assistant's source code, [Apache License 2.0](https://www.apache.org/licenses/LICENSE-2.0).

## Actions

- **Export**: Writes all messages on a specific topic into the mqtt\_dump.txt file in your configuration folder.
  Fields: Duration, Topic
- **Publish**: Publishes a message to an MQTT topic.
  Fields: Evaluate payload, Message Expiry Interval, Payload, QoS, Retain, Topic
- **Reload**: Reloads MQTT entities from the YAML-configuration.

## Troubleshooting

- **Diagnostics**: Downloads a diagnostics file to attach to a bug report.
- **Repair notices**: Notices it can show in Settings, Repairs:
  MQTT protocol migration failed, MQTT is not set up correctly

## At a glance

- Kind: Built-in integration
- Category: [Hubs and protocols](https://vulpo.app/integrations/category/hubs-and-protocols.md)
- Number: 274k installs sharing analytics
- Connection: Works locally
- Upkeep: Part of Home Assistant
- Needs: Built into Home Assistant
- Quality scale: Platinum quality scale
- Domain: `mqtt`
- Source: <https://www.home-assistant.io/integrations/mqtt/>

In Vulpo: Quick Toggle card, Cover card, Climate card, Fan card, Apple Watch, Control Center, Climate Live Activity (Pro), Vacuum Live Activity (Pro)

[Widgets & Live Activities in Vulpo](https://vulpo.app/features/widgets-and-live-activities)

Independent directory, made by the developer of Vulpo. Not affiliated with Home Assistant or the Open Home Foundation. [About these numbers](https://vulpo.app/integrations/about)

Last updated 2026-10-22. Source: https://vulpo.app/integrations/core/mqtt

---

- HTML version of this page: https://vulpo.app/integrations/core/mqtt
- Site index for agents: https://vulpo.app/llms.txt
- Everything in one document: https://vulpo.app/llms-full.txt
- All pages: https://vulpo.app/sitemap.xml
