Why pay $30 for a temperature sensor when you can build one for $8? ESPHome turns cheap ESP32 boards into custom smart home devices that integrate perfectly with Home Assistant. No coding required, just simple YAML files.
Jump to a section
Think of ESPHome as a translator between you and cheap microcontroller boards. You describe what you want in a simple YAML file, and ESPHome turns that into firmware your ESP32 can run. The result? Custom smart home devices that talk directly to Home Assistant, completely local, no cloud involved.
Write a YAML config
Describe your board, sensors, switches, and automations in plain text. No programming languages, no compilers to install.
ESPHome compiles firmware
The ESPHome add-on in Home Assistant turns your YAML into proper firmware automatically. One click, done.
Flash it to your board
Plug in your ESP32 via USB, flash the firmware, and it connects to your Wi-Fi. After the first flash, future updates happen wirelessly (OTA).
It appears in Home Assistant
Home Assistant auto-discovers your new device. All sensors, switches, and controls show up ready to use in dashboards and automations.
Commercial smart home devices are great, but they come with compromises: cloud dependencies, limited features, and prices that add up fast. ESPHome removes all three problems.
An ESP32 board costs $3 to $8. A temperature and humidity sensor costs $2 to $5. Build a complete environmental monitor for less than the price of a coffee. Commercial equivalents cost $20 to $50 each.
No cloud accounts, no subscriptions, no data leaving your home. ESPHome devices talk directly to Home Assistant on your local network. They keep working even if your internet goes down.
If you can edit a text file, you can use ESPHome. Everything is configured in YAML, the same format Home Assistant uses. No C++, no Arduino IDE, no compiling headaches.
Want a sensor that measures temperature, humidity, air pressure, and light level all in one box? Build it. Need a presence sensor that works exactly how you want? Make it. ESPHome supports hundreds of components.
After the first USB flash, all future updates happen over Wi-Fi. Change a config, hit update, and the new firmware pushes wirelessly. No crawling behind furniture to unplug devices.
ESP32 boards can act as Bluetooth proxies for Home Assistant. Place one in each room and suddenly your Bluetooth range covers your whole house. Great for Switchbot, plant sensors, and other BLE devices.
Not all boards are equal. Here's what to buy depending on your project.
BEST VALUE
$3 to $8 | Wi-Fi + Bluetooth
The workhorse. Tons of GPIO pins, dual-core processor, and massive community support. Perfect for sensors, relays, LED strips, and basically everything else. Buy a 5-pack for under $20.
BLE PROXY
$4 to $10 | Wi-Fi + BLE 5.0
Newer chips with better Bluetooth Low Energy support. Ideal for Bluetooth proxy setups where you want to extend BLE range throughout your home. The S3 also has USB native support for easier initial flashing.
VOICE
$10 to $13 | Built-in mic + speaker
A tiny cube with a built-in microphone and speaker. Flash it with ESPHome and you have a local voice assistant for Home Assistant. Think of it as a $13 Alexa replacement that respects your privacy.
DISPLAY
$12 to $18 | Built-in LCD screen
ESP32-S3 board with a small color display built in. Great for bedside clocks, thermostats, or mini dashboards. ESPHome has full display support, so you can show any data from Home Assistant.
BUDGET
$2 to $4 | Wi-Fi only
The older, cheaper option. Less memory and no Bluetooth, but perfectly fine for simple sensors and switches. If all you need is a temperature sensor or a relay, this gets the job done for under $3.
Start with one of these and you will be hooked. Each project includes what you need, approximate cost, and difficulty level.
ESP32 + DHT22 sensor. Reports temperature and humidity to Home Assistant every 30 seconds. Perfect first project because it is simple, useful, and teaches you the basics.
Parts: ESP32 dev board, DHT22 sensor, USB cable, 3D printed case (optional)
Flash an ESP32 as a Bluetooth proxy and extend BLE range throughout your house. Picks up Switchbot, Xiaomi plant sensors, and other Bluetooth devices that are too far from your server.
Parts: ESP32 board (C3 or S3 preferred), USB power adapter
ESP32 + magnetic reed switch. Know when any door or window opens. Feed this into your security automations for instant alerts.
Parts: ESP8266/ESP32, reed switch, magnet, wire
ESP32 + BME280 (temp/humidity/pressure) + optional SGP30 (VOC/CO2). Track indoor air quality and trigger automations to open windows or turn on ventilation.
Parts: ESP32, BME280 sensor, SGP30 sensor (optional), connecting wires
ESP32 + WS2812B LED strip. Create stunning ambient lighting with hundreds of effects. Control colors and brightness from Home Assistant or the WLED app. Works great with your lighting automations.
Parts: ESP32, WS2812B strip (1-5m), 5V power supply, level shifter (optional)
Many cheap Tuya/Smart Life plugs have ESP chips inside. Flash them with ESPHome and they become local, cloud-free smart plugs with energy monitoring. Check devices on devices.esphome.io first.
Parts: Compatible smart plug (check Athom or CloudFree pre-flashed options)
ESP32 + LD2410 radar sensor. Detects presence even when you are sitting still, unlike PIR motion sensors. Use it for automations like keeping lights on while you are reading.
Parts: ESP32, HLK-LD2410 or LD2450 module, USB power
M5Stack ATOM Echo + ESPHome voice assistant firmware. A privacy-first voice assistant for $13 that works with Home Assistant's Assist pipeline. No Amazon or Google listening in.
Parts: M5Stack ATOM Echo, USB-C cable
ESP32 + SCT-013 current transformer. Monitor your whole home's electricity usage in real time. Feed data into Home Assistant's energy dashboard for detailed tracking.
Parts: ESP32, SCT-013 CT clamp, burden resistor, 3.5mm jack
ESP32 + Waveshare e-ink display. Build a low-power display that shows weather, calendar events, or sensor readings. E-ink screens use almost no power and look great in any room.
Parts: ESP32, Waveshare e-paper display (2.9" or 4.2"), connecting wires
From zero to your first working device in about 30 minutes. Here is the quickest path.
In Home Assistant, go to Settings โ Add-ons โ Add-on Store and search for ESPHome. Install it and start it. This gives you a web dashboard where you manage all your ESPHome devices.
If you are running Home Assistant in Docker (not HAOS), you can run ESPHome as a standalone Docker container instead.
Click "New Device" in the ESPHome dashboard. Give it a name (like "living-room-sensor"), pick your board type (ESP32 or ESP8266), and enter your Wi-Fi credentials. ESPHome generates the base config for you.
Edit the YAML config and add whatever sensors or outputs you have wired up. Here is a temperature sensor example:
sensor:
- platform: dht
pin: GPIO4
temperature:
name: "Living Room Temperature"
humidity:
name: "Living Room Humidity"
update_interval: 30sFor the first flash, connect your ESP32 via USB and click "Install" in the ESPHome dashboard. Choose "Plug into this computer" and select the USB port. The firmware compiles and flashes automatically. Takes about 2 minutes.
Alternative: use web.esphome.io to flash directly from your browser using Web Serial. No add-on needed.
Home Assistant should auto-discover your new device within seconds. Go to Settings โ Devices & Services and look for the ESPHome integration. Click configure, and all your sensors and entities appear. Done. Use them in dashboards and automations just like any other device.
ESPHome is not always the answer. Here is when to build and when to buy.
Lessons from the community that will save you hours of troubleshooting.
DHCP can change your device's IP and cause connection drops. Set a static IP in the YAML config or reserve it in your router. This is the number one fix for "device keeps going offline" issues.
ESP boards only support 2.4GHz Wi-Fi. If your router merges 2.4 and 5GHz into one SSID, create a separate 2.4GHz network for your IoT devices. Better range, fewer connection issues.
Cheap USB cables are the cause of 90% of "I can't flash my board" problems. If your board isn't detected, try a different cable. Make sure it is a data cable, not just a charging cable.
Your ESPHome YAML files are stored in the config directory. Back them up regularly. If you reinstall Home Assistant, your devices keep running but you will need the configs to make changes.
ESPHome creates a fallback Wi-Fi hotspot if it cannot connect to your network. This saves you from having to reflash via USB if you change your Wi-Fi password or move to a new house.
Companies like Athom and CloudFree sell devices pre-flashed with ESPHome. Smart plugs, light bulbs, relay boards, all ready to configure. Skip the hardware tinkering and go straight to YAML.
ESPHome opens up a whole new level of smart home possibilities, from flashing your first ESP32 to converting Tuya plugs. Start with a starter kit, run a free device compatibility scan, and see what your smart home could become.
ESPHome is a tool that turns cheap ESP32 and ESP8266 microcontroller boards into smart home devices. You write a simple YAML configuration file describing what sensors, switches, or displays you want, and ESPHome compiles it into firmware that flashes directly onto the board. Once running, the device automatically connects to Home Assistant over your local network. No cloud, no coding, no subscription fees.
No. ESPHome uses YAML configuration files, not programming code. You describe what hardware you have connected and what you want it to do, and ESPHome handles the rest. If you can edit a text file, you can use ESPHome. The Home Assistant add-on even has a visual editor for common configurations.
The ESP32-WROOM-32 development board is the most popular choice, typically costing between $3 and $8. For projects needing Bluetooth proxy support, grab an ESP32-C3 or ESP32-S3 board. If you want the easiest possible start, the M5Stack ATOM Lite or ATOM Echo are pre-built ESP32 devices with cases that work great with ESPHome right out of the box.
An ESP32 board costs about $3 to $8. Common sensors like DHT22 (temperature and humidity) cost around $2 to $5. A complete temperature sensor project can cost under $10 total. Compare that to commercial Zigbee sensors at $15 to $30 each. The tradeoff is that ESPHome devices need Wi-Fi and a power source, and you spend time on setup instead of money on products.
ESPHome is 100% local. Your devices communicate directly with Home Assistant over your Wi-Fi network. No data ever leaves your home, no cloud accounts needed, no subscriptions, and everything keeps working if your internet goes down. The only time you need internet is during the initial firmware compilation if you use the Home Assistant add-on.