Skip to content

Quick Start

This guide will help you create a simple BTHome temperature and humidity sensor.

esphome:
name: bthome-sensor
friendly_name: BTHome Sensor
esp32:
board: esp32dev
framework:
type: esp-idf
logger:
wifi:
ap:
ssid: "BTHome-Sensor"
captive_portal:
external_components:
- source:
type: git
url: https://github.com/dz0ny/esphome-bthome
ref: main
components: [bthome]
# I2C for BME280 sensor
i2c:
sda: GPIO21
scl: GPIO22
scan: true
sensor:
- platform: bme280_i2c
address: 0x76
temperature:
id: bme_temperature
name: "Temperature"
humidity:
id: bme_humidity
name: "Humidity"
pressure:
id: bme_pressure
name: "Pressure"
update_interval: 30s
# BTHome configuration
bthome:
sensors:
- type: temperature
id: bme_temperature
- type: humidity
id: bme_humidity
- type: pressure
id: bme_pressure
  1. Compile the configuration:

    Terminal window
    esphome compile your_config.yaml
  2. Flash to your device:

    Terminal window
    esphome upload your_config.yaml
  3. Monitor the logs to verify it’s working:

    Terminal window
    esphome logs your_config.yaml

Once your device is running:

  1. Open Home Assistant
  2. Go to SettingsDevices & ServicesBTHome
  3. Your device should appear automatically
  4. Click Configure to add it

You should now see your temperature, humidity, and pressure sensors in Home Assistant!