Skip to main content

Xiaomi Miio (WiFi products)

Xiaomi offers a wide range of smart home devices - robotic vacuums, air purifiers, fans, etc. - that can be integrated into Home Assistant using the Xiaomi Miio integration.

I tested the integration process on two products:

  • Xiaomi Roborock S50 (S5) vacuum cleaner, which I have had since 2018 and it still works great. Today, very similar vacuums are available at much lower prices, or for a similar price, you can buy a vacuum with a base that can "dump" the dirt.

    wifi
    Roborock Q8 Max White

    Roborock Q8 Max White

    Robotický vysavač s mopem.
    wifi
    Xiaomi Robot Vacuum S20 White

    Xiaomi Robot Vacuum S20 White

    Robotický vysavač s mopem.
    wifi
    Roborock Qrevo S white

    Roborock Qrevo S white

    Robotický vysavač s mopem a základnou
    Integration of new Roborock models

    Newer models - approximately from the Roborock S7 model - may no longer work in the Xiaomi app or may not have all functions available. In such a case, add the vacuum to the Roborock app and use the Roborock integration for Home Assistant.

  • Xiaomi Mi Purifier 2S air purifier, which I have also had since 2018. In addition to air purification, it provides information about temperature, humidity, and PM2.5 particulate matter in the room.

    wifi
    Xiaomi Smart Air Purifier 4

    Xiaomi Smart Air Purifier 4

    Čistička vzduchu - 55x25x25cm. Výkon 400 m³/h, příkon 30 W, doporučená velikost místnosti do 48 m²
    wifi
    Xiaomi Smart Air Purifier 4 Pro

    Xiaomi Smart Air Purifier 4 Pro

    Čistička vzduchu - 68x27x27cm. Výkon 500 m³/h, příkon 50 W, doporučená velikost místnosti do 60 m²
    wifi
    Xiaomi Smart Air Purifier 4 Compact

    Xiaomi Smart Air Purifier 4 Compact

    Čistička vzduchu - 35x22x22cm. Výkon 230 m³/h, příkon 27 W, doporučená velikost místnosti do 27 m²

Xiaomi Mi Home App

Not only for integration into HA but also for usage, you will need to install the Xiaomi Mi Home app on your mobile phone.

Download on Google PlayDownload on the App Store

Integrating Xiaomi into HA

  1. Adding the Xiaomi Miio Integration:

    • Automatically - if the Xiaomi device is on the same network as Home Assistant, it should be found automatically using the auto-discovery feature. You will find it in the Integrations section under Discovered, for example, the mentioned air purifier in my case:

      Xiaomi HA discovery auto

    • Manually:

      • Go to the Settings -> Devices & Services menu and make sure you are on the Integrations tab.
      • Click on Add Integration and search for Xiaomi Miio.

      Or click on:

      Open your Home Assistant instance and start setting up a new integration.
  2. Logging into Xiaomi Cloud

    • Enter your Xiaomi cloud credentials in the username field

    • Enter your password

    • In the Cloud Server Country field, select de for most products

      Cloud Server Country

      Some Xiaomi products cannot be added to the European (DE) server in the Mi Home App and need to be registered in mainland China. In such a case, select cn.

      Xiaomi HA discovery auto

    • If you added Xiaomi Miio using auto discovery, there is no need to fill in the product and you can directly set the area

    Xiaomi HA discovery auto

    • Otherwise, you need to first select the device to add from the list of your products registered through Xiaomi cloud.

      Xiaomi HA discovery auto

  3. New Entities:

    Depending on the product type, you should find several new entities for the device, which can be used to control the device and possibly obtain sensor data - for example, temperature, humidity for the air purifier, and many sensors for cleaning for the robotic vacuum.

    Xiaomi HA discovery auto
    Xiaomi HA discovery auto

Comments