Skip to main content

Extending Home Assistant's Bluetooth Range With an ESP32 Proxy

·693 words·4 mins
Ifesinachi Osude
Author
Ifesinachi Osude
I build production infrastructure for a living — and a private cloud in my closet for fun.

What happens when you want to automate a Bluetooth device, but it is too far away from your Home Assistant server?

That was the problem I ran into with my AC Infinity AirTap. Home Assistant runs on a NUC in my office, while the AirTap is located elsewhere in the house. The NUC’s Bluetooth adapter could not reliably reach it, so I was limited to controlling the device with my phone.

The solution was to build a Bluetooth proxy with an ESP32 development board.

ESP32 DevKitC-32 board

Using an ESP32 as a remote Bluetooth bridge
#

An ESP32 can connect to Wi-Fi and act as a remote Bluetooth Low Energy adapter for Home Assistant. The ESP32 is placed near the Bluetooth device, while Home Assistant continues to provide the integrations, controls, and automation logic.

The setup looks like this:

Bluetooth device
        │ BLE
ESP32 Bluetooth Proxy
        │ Wi-Fi
Home Assistant

This changes the range problem from “Is the device close enough to the server?” to “Can I place a small, Wi-Fi-connected proxy close enough to the device?”

That makes the same approach useful for Bluetooth devices in bedrooms, garages, basements, workshops, barns or any other area where the main Home Assistant host cannot maintain a reliable connection.

The hardware
#

I used a standard ESP32 development board, powered over USB. The proxy needs reliable 2.4 GHz Wi-Fi and a good Bluetooth connection to the devices it will serve. Placement matters, so it should be kept in an open location and away from unnecessary radio interference where possible.

The board is inexpensive, small, and flexible enough to serve more than one compatible BLE device in its area. Multiple proxies can also be deployed around a house when one ESP32 cannot provide enough coverage.

The configuration
#

The ESP32 runs ESPHome with Bluetooth proxy support enabled. The configuration is intentionally kept out of this post so that the repository remains the single source of truth for the working files.

The Bluetooth proxy directory in my Home Assistant repository contains the white-labeled YAML configuration, README, flashing instructions, example secrets, and implementation notes.

The configuration includes the ESPHome Bluetooth tracker and an active Bluetooth proxy. It also shows the supporting Wi-Fi, Home Assistant API, MQTT, logging, and OTA settings needed for the device.

If you use the files, update the board name, Wi-Fi settings, MQTT settings, and API encryption key for your own installation. Secrets should never be committed to a public repository.

Automating the AirTap
#

Once the proxy was online, Home Assistant could communicate with the AirTap through the ESP32. That allowed me to connect it to the rest of my HVAC automation.

I paired it with my Ecobee Pro thermostat so the AirTap turns on when the air conditioning is running and turns off when the cooling cycle ends. Previously, I generally left it running because controlling it manually with my phone was inconvenient. Now it operates automatically and only runs when it is useful.

The important part is not the specific AirTap automation. The proxy makes a previously unreachable Bluetooth device available to Home Assistant, which means it can participate in any automation that Home Assistant supports.

What else can it do?
#

The proxy can forward BLE advertisements and discovery data, along with supported active Bluetooth connections and GATT operations for compatible Home Assistant integrations.

It is not a universal bridge for every Bluetooth device. It is intended for Bluetooth Low Energy devices, and the target device still needs to be supported by Home Assistant. Active Bluetooth connections also have finite connection capacity, although passive BLE advertisements are handled separately.

Final thoughts
#

Bluetooth range is easy to overlook until the device you want to automate is on the other side of the house. An ESP32 Bluetooth proxy is a simple way to extend that range without moving the Home Assistant server or adding a long cable to a Bluetooth adapter.

For me, it turned the AC Infinity AirTap from a phone-controlled device into a fully automated part of my HVAC system. More broadly, it provides a reusable way to bring remote BLE devices into Home Assistant wherever they are needed.