config/custom_components/, restart Home Assistant, then add it under Settings > Devices & services > Add integration. It works like a built-in integration, but nobody at Home Assistant has reviewed the code, so update it carefully.Updated November 2026 for Home Assistant 2026.10 and 2026.11. This guide was rewritten for beginners. The developer part is still here, just shorter and closer to the bottom.
A Home Assistant custom integration fills a gap. Home Assistant ships with more than two thousand integrations, but sooner or later you find a device, a local energy provider or a web service that is missing. Very often someone has already written a custom integration for it and shared it on GitHub.
Below you will learn what an integration actually is, how a custom integration is different, how to install one with HACS or by hand, how to add it, what can go wrong, and how to remove it cleanly. At the end there is a small working example if you want to build your own.
What is an integration in Home Assistant?
An integration is the piece of Home Assistant that knows how to talk to one brand, device or service. The Shelly integration talks to Shelly relays, the Google Cast integration talks to Chromecast speakers, the Met.no integration fetches the weather forecast. Each integration turns what it finds into entities. An entity is one thing Home Assistant can see or control, like a light, a temperature sensor or a switch.
You manage all of them in one place: Settings > Devices & services. That screen lists every integration you have set up, and each one shows the devices and entities it created.
SONOFF ZBDongle-E (Zigbee 3.0 USB)Cheap, well supported Zigbee coordinator for ZHA or Zigbee2MQTT.Check price on AliExpressAqara Motion Sensor P1 (Zigbee)Fast, long battery life motion sensor for lighting automations.Check price on AliExpressIntegration vs custom integration
A normal (core) integration is part of Home Assistant itself. It is reviewed by the Home Assistant team, tested before each release and updated together with Home Assistant.
A custom integration is code written by someone outside that process. It lives in a folder called custom_components inside your configuration folder, and Home Assistant loads it at startup just like a core integration. The difference is about trust and maintenance, not about features:
- Core integration: installed already, reviewed, updated with every Home Assistant release.
- Custom integration: you install it yourself, nobody at Home Assistant checks it, and you update it separately.
You will see a warning in the logs for every custom integration, saying it has not been tested by Home Assistant. That is normal and does not mean something is broken.
Before you install: the risks
Custom integrations are very useful, and most popular ones are well maintained. Still, know what you are signing up for:
- Unofficial code. A custom integration runs with the same access as Home Assistant itself. Stick to projects with many users, recent releases and an active issue page.
- Breaking changes. Home Assistant changes its internal code every month. An old custom integration can stop loading after an update until its author releases a fix.
- Abandoned projects. If the author loses interest, the integration slowly breaks. Check when the last release happened before you depend on it.
- Name clashes. If a custom integration uses the same name (domain) as a core integration, it replaces the core one. Some projects do this on purpose to offer a newer version, but it means you no longer get the official fixes.
Take a backup before you install or update one. If Home Assistant misbehaves, you can always roll back.
How to install a custom integration with HACS
HACS (Home Assistant Community Store) is itself a custom integration that acts as a store for other community code. It downloads integrations, tells you when updates are out and can remove them again. If you do not have it yet, follow our guide on how to install HACS first.
- Open HACS from the Home Assistant sidebar.
- Search for the integration by name and click it to open its page. Read the description, it often lists extra setup steps.
- Click Download in the bottom right corner and confirm. The newest version is picked by default.
- HACS marks it as “Pending restart”. Restart Home Assistant from the repair notice HACS creates, or from Settings > System and the power icon in the top right.
- Add the integration as described in the next section.
If the integration you want is not listed, its author may not have submitted it to HACS yet. You can still add its GitHub address as a custom repository from the three-dot menu in the top right of HACS. Only do this for projects you trust.
How to install a custom integration manually
Without HACS you copy the files yourself. You need access to your configuration folder, for example with the File editor or Studio Code Server app, or the Samba share app on Home Assistant OS. (Apps were called add-ons until early 2026.)
- Download the latest release of the integration from its GitHub page, usually a zip file.
- Inside the zip, find the folder under
custom_components. Its name is the integration’s domain, for examplehello_home. - Copy that folder into
config/custom_components/. Create thecustom_componentsfolder if it does not exist yet. - Restart Home Assistant.
When you are done, the folder structure looks like this:
config/
configuration.yaml
custom_components/
hello_home/
__init__.py
manifest.json
config_flow.py
sensor.py
The most common mistake is one folder too many, like custom_components/hello_home/hello_home/. The manifest.json file must sit directly inside the domain folder, or Home Assistant will not find it.
How to add the integration in Home Assistant
Downloading the files is only half the job. Most custom integrations are set up from the UI, exactly like core ones:
- Go to Settings > Devices & services.
- Click Add integration in the bottom right.
- Search for the integration by name and select it.
- Fill in what it asks for, like an IP address, an API key or a login, and finish the wizard.
If the integration does not show up in the list, clear your browser cache and check the logs under Settings > System > Logs for an error about it. A few older custom integrations are configured with YAML in configuration.yaml instead. Their README tells you which lines to add. YAML is the plain text format Home Assistant uses for settings.
Once it is set up, its entities work everywhere: dashboards, automations and helpers like a template sensor.
Keeping custom integrations up to date
HACS shows available updates in the same Settings > System > Updates list as Home Assistant itself. Before you click update:
- Read the release notes on GitHub. Authors usually mention breaking changes there.
- Update Home Assistant and your custom integrations at different times. If something breaks, you know which change caused it.
- After a big Home Assistant update, check that every custom integration still loads. A failed one shows a notification and an error in the logs.
If Home Assistant will not start properly after an update, restart in safe mode. It is in the restart menu under More options and starts Home Assistant without any custom integrations, so you can tell whether one of them is the cause. The official page on restarting Home Assistant shows where to find it.
How to remove a custom integration
- Go to Settings > Devices & services, open the integration, click the three-dot menu next to its entry and choose Delete. Repeat for every entry it has.
- Remove any YAML lines you added for it in
configuration.yaml. - Remove the files. In HACS, open the integration’s three-dot menu and choose Remove. If you installed it by hand, delete its folder from
config/custom_components/. - Restart Home Assistant.
Do it in this order. If you delete the files first, the leftover entry shows up as “not loaded” and is harder to clean up.
Build your own custom integration
If nobody has written the integration you need, you can make one. You need some Python knowledge. Python is the programming language Home Assistant is written in. A minimal integration that adds one sensor from the UI needs four small files in config/custom_components/hello_home/.
1. manifest.json
This file describes the integration. The domain must match the folder name. Custom integrations must also have a version, or Home Assistant refuses to load them.
{
"domain": "hello_home",
"name": "Hello Home",
"codeowners": ["@your-github-name"],
"config_flow": true,
"documentation": "https://github.com/your-github-name/hello_home",
"integration_type": "service",
"iot_class": "calculated",
"issue_tracker": "https://github.com/your-github-name/hello_home/issues",
"requirements": [],
"version": "0.1.0"
}
"config_flow": true tells Home Assistant it can be added from the UI. iot_class says how it gets data: calculated means it does not talk to any device, while a real integration uses values like local_polling or cloud_push.
2. config_flow.py
The config flow is the setup wizard you see after clicking Add integration. This one has no questions. It only allows one copy and creates the entry when you click submit.
from homeassistant.config_entries import ConfigFlow
DOMAIN = "hello_home"
class HelloHomeConfigFlow(ConfigFlow, domain=DOMAIN):
"""Add Hello Home from the UI."""
VERSION = 1
async def async_step_user(self, user_input=None):
await self.async_set_unique_id(DOMAIN)
self._abort_if_unique_id_configured()
if user_input is not None:
return self.async_create_entry(title="Hello Home", data={})
return self.async_show_form(step_id="user")
3. __init__.py
This file runs when the entry is set up. It hands the work to the sensor platform and cleans up when you delete the entry.
from homeassistant.config_entries import ConfigEntry
from homeassistant.const import Platform
from homeassistant.core import HomeAssistant
PLATFORMS = [Platform.SENSOR]
async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Set up Hello Home from a config entry."""
await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
return True
async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
"""Unload a config entry."""
return await hass.config_entries.async_unload_platforms(entry, PLATFORMS)
4. sensor.py
from homeassistant.components.sensor import SensorEntity
async def async_setup_entry(hass, entry, async_add_entities):
"""Create the sensor for this entry."""
async_add_entities([HelloSensor(entry.entry_id)])
class HelloSensor(SensorEntity):
"""A sensor that always says hello."""
_attr_name = "Hello message"
_attr_icon = "mdi:hand-wave"
def __init__(self, entry_id):
self._attr_unique_id = f"{entry_id}_message"
self._attr_native_value = "Hello from my custom integration"
Restart Home Assistant, add “Hello Home” from Add integration, and a new sensor appears with the text as its state. From here, a real integration replaces the fixed text with data from a device or an API, using async code so it never blocks Home Assistant while it waits for the network.
For the next steps, like options flows, translations, polling with a data coordinator and tests, use the official developer documentation. It moved from developers.home-assistant.io to contributors.home-assistant.io, and the manifest page is a good place to start. If you only need to call a few actions from your own code, our guide to custom components and action calls covers that part. And if you want a safe place to experiment, a spare Raspberry Pi with Home Assistant makes a good test box.
Frequently Asked Questions
What is a custom integration in Home Assistant?
It is an integration written by the community instead of the Home Assistant team. It lives in the config/custom_components folder and connects Home Assistant to a device or service that has no official integration. It works the same way as a built-in one, but nobody at Home Assistant reviews or tests it.
How do I install a custom integration?
The easiest way is HACS: search for it, click Download and restart Home Assistant. Without HACS, copy the integration’s folder into config/custom_components/ and restart. In both cases, finish by adding it under Settings > Devices & services > Add integration.
Why does my custom integration not show up in Add integration?
Usually Home Assistant was not restarted after the files were added, the folder is nested one level too deep, or the manifest.json is missing a version. Check Settings > System > Logs for an error that names the integration, then clear your browser cache and try again.
Are custom integrations safe?
Popular, well maintained ones are generally fine, but the code is not reviewed by Home Assistant and runs with full access to your system. Prefer projects with many users and recent releases, take a backup before installing or updating, and remove integrations you no longer use.





