Xiaomiβs robot vacuum cleaners have become an integral part of smart homes, but full management through third-party applications (such as Home Assistant, ioBroker or Node-RED) requires a special access token. This unique key allows you to integrate the device into ecosystems not limited to the official Mi Home app. However, the process of obtaining it is often questionable β especially for users who are first to face the setup of smart equipment.
In this article, we will look at all the current ways to obtain a token for Xiaomi vacuum cleaners (including Mi Robot Vacuum, Viomi, Dreame and others), as well as look at typical errors and their solutions. It is important to understand that the methods differ depending on the region of the device binding (China, Europe, Russia) and the firmware version. We updated the instructions for the changes in 2026 β now they work even for new devices with enhanced protection.
What is Xiaomi vacuum cleaner token and why you need it
A token is a unique alphanumeric key that identifies your device in the Xiaomi cloud.
- π Integration with smart home systems (Home Assistant, OpenHAB, Domoticz) Without the token, the vacuum cleaner will not appear in these platforms.
- π± Control through alternative applications (e.g. Valetudo for local control without cloud).
- π οΈ Automation of tasks (creating schedule cleaning scenarios, sensor-based triggers).
- π§ Diagnostics and debugging (viewing logs, testing new features through API).
The official Mi Home app hides the token from the user, as Xiaomi does not support an open API for third-party developers, but enthusiasts have found workarounds, which we will discuss later.
β οΈ Note: Receiving a token may violate Xiaomiβs terms of use, and in rare cases, it results in account blocking (usually when massive requests are made to the user). API). Use methods at your own risk and risk.
Method 1: Receiving a token through Mi Home (the official method for older versions)
This method worked until 2022 for devices tied to the Chinese region (cn). Now it is only relevant for vacuum cleaners with firmware older than 3.5.8. If your device is new, go to Method 2.
Instructions:
- Open the Mi Home app and go to the vacuum cleaner settings (Profile β Device settings β General).
- Click on the three dots in the upper right corner and select About.
- Tap 5-7 times according to the firmware version until the developer menu appears.
- In the window that opens, find the Token line β this is your key.
If there is no Token, it means:
- π The device is tied to a non-Chinese region (Europe, Russia).
- π Newer than 3.5.8 firmware β Xiaomi has removed this feature.
- π± You are using a non-original version of the Mi Home (e.g., modified for Russia).
Method 2: Extracting a token through HTTP-interception (current for 2026)
The most reliable method to date is to intercept network traffic between the Mi Home app and Xiaomi servers, which would require:
- π± Android smartphone (on iOS method does not work due to system limitations).
- π Traffic interception software (HTTP Toolkit, Fiddler or Packet Capture).
- π Root rights are not required, but you need to install an interception certificate.
Step-by-step:
- Install the program to intercept (we recommend the HTTP Toolkit β it is easier to configure).
- Set up a proxy: On Android: go to Settings β Wi-Fi β [your network] β Additional β Proxy Server. Specify IP and port from the program (e.g. 192.168.1.100:8080).
Install the certificate
- In HTTP Toolkit, go to the Certificates tab and download the certificate for Android.
- Install it on your phone (you will need to unlock the installation from unknown sources).
- Launch the intercept and open Mi Home.
- Update the vacuum cleaner data (for example, click on it in the main menu).
- Find a request with URL, containing /home/device_list or /miot-spec/v2/.
- Copy the token from the token field in the server response.
| Region | Probability of success | Need a VPN? | Notes |
|---|---|---|---|
| China (cn) | 90% | Yes. | The most reliable option, but you need a Chinese SIM or VPN with a Chinese IP. |
| Europe (eu) | 70% | No. | It works for most models, except for the new Dreame. |
| Russia (ru) | 10% | No. | The token is almost never displayed. |
| USA (us) | 50% | No. | Often requires confirmation by SMS. |
π‘
If the vacuum cleaner is not added when changing the region, try to reset it to the factory settings (press the power button for 10 seconds).
Method 4: Use of third-party utilities (for advanced users)
If the manual methods do not work, you can use specialized tools:
- π₯οΈ MiTokenextractor β Python script for automatic token extraction from Mi Home backup.
- π± Packet Capture (Android) is a simplified alternative HTTP Toolkit for mobile devices.
- π Online services (e.g. Xiaomi Cloud Tokens Extractor) β operate through Xiaomi account authorization but are not secure (risk of data leakage).