whatisgithub

What is switchbot-humidifier-esphome?

phdindota/switchbot-humidifier-esphome — explained in plain English

Analysis updated 2026-07-25

0C++Audience · developerComplexity · 4/5Setup · hard

In one sentence

Custom open-source firmware for the SwitchBot Evaporative Humidifier 2 that lets you control it locally using ESPHome and Home Assistant instead of the SwitchBot app and cloud.

Mindmap

mindmap
  root((repo))
    What it does
      Replaces SwitchBot firmware
      Local control via Home Assistant
      Four fan speeds
      Auto and Sleep modes
    Setup requirements
      USB-to-serial adapter
      3.3V serial connection
      Command-line tools
      Backup original firmware
    Safety
      Mains power appliance
      Disconnect from wall
      Contains water
    Current features
      Water level detection
      Filter usage tracking
      Automatic filter drying
      Target humidity control
    Not yet implemented
      Front-panel display
      LED animations
      Beeps
      Child lock
    Target hardware
      SwitchBot Humidifier 2
      Model W3902310
      V07 mainboard

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

What do people build with it?

USE CASE 1

Control your SwitchBot humidifier locally without relying on the SwitchBot cloud or app.

USE CASE 2

Set target humidity levels and automate humidifier operation from Home Assistant.

USE CASE 3

Track filter usage and run automatic filter-drying cycles to extend filter life.

What is it built with?

C++ESPHomeESP32Home Assistant

How does it compare?

phdindota/switchbot-humidifier-esphomeachanana/mavsdkalange/llama.cpp
Stars00
LanguageC++C++C++
Last pushed2024-05-20
MaintenanceDormant
Setup difficultyhardmoderatemoderate
Complexity4/54/54/5
Audiencedeveloperdeveloperdeveloper

Figures from each repo's GitHub metadata at analysis time.

How do you get it running?

Difficulty · hard Time to first run · 1h+

Requires opening a mains-powered humidifier and flashing via a 3.3V serial connection to the internal circuit board.

So what is it?

{"i": 0, "repo": "phdindota/switchbot-humidifier-esphome", "stars": 0, "lang": "C++", "ok": true, "char_count": 1899, "text": "This project replaces the software inside a specific SwitchBot humidifier with custom open-source firmware. The target is the SwitchBot Evaporative Humidifier 2, model W3902310, using the V07 mainboard. By swapping the firmware, you take control of the appliance away from the SwitchBot app and cloud, and instead run it through ESPHome and Home Assistant, which are open-source smart home platforms.\n\nThe core humidification functions are working on real hardware. The fan spins at four speed levels, the device detects water levels, and the filter gets wet after an eight-second startup delay. You can control it from Home Assistant, set target humidity levels, and use Auto and Sleep modes. The project also tracks filter usage and starts an automatic filter-drying cycle. However, several features are not yet implemented: the front-panel segment display, LED animations, beeps, the child lock, and individual button mappings. The original SwitchBot app, cloud, Bluetooth, and Matter connections are all replaced by the ESPHome and Home Assistant setup.\n\nFlashing the device involves serious safety considerations. The humidifier is a mains-powered appliance that contains water, and the project authors stress that you must disconnect it from wall power before opening it. You connect to the internal circuit board using a 3.3 V serial connection, never 5 V, through a specific set of pins labeled J3. The guide walks you through backing up the original 4 MB firmware before installing the replacement, and it recommends keeping that backup private since it may contain device-specific calibration data.\n\nThe installation process is aimed at people comfortable with command-line tools and low-voltage electronics. You use a USB-to-serial adapter to communicate with the ESP32 chip inside the humidifier, enter a download mode by manipulating specific pins, and then write the new firmware. The project provides a detailed pinout table and step-by-step instructions for backing up the original software and configuring the new setup, including optional room sensors for smarter humidity control.\n\nThis appears to be the first publicly documented working ESPHome port for this humidifier model, though the authors acknowledge private projects may exist. The firmware is experimental and not a complete clone of the original. The filter-dry cycle duration is set to 55 minutes in the configuration, while the original manufacturer uses 70 minutes, and you can adjust this value yourself.\n\nThe full README is longer than what was shown.", "error": null}

Copy-paste prompts

Prompt 1
Write a Home Assistant automation that turns on my SwitchBot humidifier when the room humidity drops below 45% and sets it to Auto mode.
Prompt 2
Help me configure an ESPHome room sensor setup so my humidifier adjusts its target humidity based on readings from multiple rooms.
Prompt 3
Generate an ESPHome YAML snippet to adjust the filter-dry cycle duration from the default 55 minutes to 70 minutes for my SwitchBot humidifier.

Frequently asked questions

What is switchbot-humidifier-esphome?

Custom open-source firmware for the SwitchBot Evaporative Humidifier 2 that lets you control it locally using ESPHome and Home Assistant instead of the SwitchBot app and cloud.

What language is switchbot-humidifier-esphome written in?

Mainly C++. The stack also includes C++, ESPHome, ESP32.

How hard is switchbot-humidifier-esphome to set up?

Setup difficulty is rated hard, with roughly 1h+ to a first successful run.

Who is switchbot-humidifier-esphome for?

Mainly developer.

Open on GitHub → Ask about another repo

This repo across BitVibe Labs

Verify against the repo before relying on details.