Connecting Xiaomi Smart Switch with Zero Wire: Instructions from A to Z

Xiaomi’s zero-wire smart switches are a modern lighting automation solution that requires proper installation and tuning. Unlike classic switches, these devices require constant power, which is provided by a zero-wire connection. Without them, the smart module will not be able to run in standby mode, receive commands from a smartphone or interact with other devices in the Mi Home ecosystem.

In this article, we will learn how to connect a Xiaomi zero wire switch yourself, even if you have never had any wiring, what tools you will need, how to determine the zero and phase wires, and how to avoid typical installation errors, and focus on setting up the device in the Mi Home app and integrating with voice assistants.

Important: Electricity requires safety, and if you are not sure of your skills, it is better to entrust the installation to a professional electrician. The article provides general guidelines, but the specific circuitry may depend on the switch model (for example, Aqara Wall Switch or Xiaomi Mi Smart Wall Switch) and the characteristics of your electrical wiring.

What Xiaomi switches require zero wire?

Not all Xiaomi smart switches need zero wire connection, and typically zero wire requirement occurs for devices that:

  • πŸ”Ή Operate in a constant power mode (for example, to control via Wi-Fi or Zigbee without batteries).
  • πŸ”Ή Support dimming (brightness adjustment) of lamps.
  • πŸ”Ή Have a built-in display or display (e.g. Aqara Wall Switch) H1).
  • πŸ”Ή Equipped with a relay module that requires power to hold the state (on/off).

Among the popular models that require zero wire, we can distinguish:

  • πŸ”Œ Xiaomi Mi Smart Wall Switch (neutral wire required)
  • πŸ”Œ Aqara Wall Switch D1 (single- and two-key versions)
  • πŸ”Œ Aqara Wall Switch H1 (sensory)
  • πŸ”Œ Xiaomi Mi Wireless Switch (wireless models do not require zero, but their functionality is limited)

If your model is not listed, check the specifications on the official website or in the instructions. Usually, the requirement for zero wire is specified in the section "Installation requirements" or "Electric parameters".

πŸ“Š What Xiaomi switch you plan to install?
Aqara Wall Switch D1
Xiaomi Mi Smart Wall Switch
Aqara Wall Switch H1
Another model
Not yet.

Connection tools and materials

Before you start, you have to prepare everything you need, and without the right tools, you're at risk of damaging the wiring or the device itself.

Tool/materialAppointmentNote
Indicator screwdriverVerification of phase availabilityIt's a security requirement!
Flat and cross screwdriver.Dismantling the old switch, fastening the newSize up by mounting.
Bokoroska/snippetsCutting and cleaning of wiresPreferably with isolated handles
Strain or shrink tubeInsulation of compoundsThermal shrink tube is more reliable
Multimeter (optional)Accurate testing of voltage and resistanceHelps with complex schemes

You may also need to:

  • πŸ”§ Retardant (if the old one is damaged or not fitting in size).
  • πŸ”§ Wire extension (if there are not enough regular wires for connection).
  • πŸ”§ Marker or stickers for marking wires.
  • πŸ”§ Lantern (working in a rosette without light is uncomfortable).

Important: If you have aluminum wiring in your house and the switch is designed for copper wires, use special terminals or adapters. The direct connection of aluminum and copper leads to oxidation and overheating!

Step-by-step instruction: connecting a zero-wire switch

Now, to the process itself, follow the instructions carefully to avoid mistakes.

Turn off the machine on the shield.|Check the absence of voltage indicator|Dismantling the old switch|Clean the wires by 5-7 mm|Mark the wires (phase, zero, load)-->

Step 1: Turn off the electricity and remove the old switch

First of all, turn off the machine that controls the lighting line in your room. Don't just limit yourself to the switch, it breaks the phase, but zero stays on!

Take the keys off the old switch (usually on the latches) and unscrew the screws that hold the mechanism in the rosette. Gently pull the device out and inspect the wires. If the wires are short, you can lengthen them a little, but not more than 10-15 cm.

Step 2: Determine phase and zero

Turn the machine back on, and with the indicator screwdriver, find the phase wire. When you touch the phase, the indicator will light up. Zero and ground (if any) do not cause glow. You can use a multimeter for accuracy:

  • πŸ”‹ Set the variable voltage measurement mode (~220V).
  • πŸ”‹ One probe to the phase, the other to the supposed zero. ~220V.
  • πŸ”‹ If you touch the phase and the ground, the stress will be the same (in modern homes).
  • πŸ”‹ There will be no tension between zero and the earth.

After checking, turn off the machine again and mark the wires.

  • πŸ”΄ L – phase (usually red or brown wire).
  • πŸ”΅ N = zero (blue or blue).
  • 🟒 PE β€” earth).
  • 🟑 Load - load (goes to the lamp, can be of any color).

πŸ’‘

If the rosette doesn't have zero wire, and the switch requires it, you can reach zero from the nearest outlet. 3Γ—1.5 But it's better to trust an electrician with this installation.

Step 3: Connecting wires to a smart switch

The connection scheme depends on the model, but the general principle is as follows:

  1. Connect the phase wire (L) to the L or Live terminal on the switch.
  2. Connect the zero wire (N) to the terminal N.
  3. Connect the Load (Load) to the terminal L1 (or L2, double-key).
  4. If there's land (PE), connect it to the appropriate terminal (usually indicated by a symbol) ⏚).

On the back of the Xiaomi switch, there's usually a connection circuitry. for example, for the Aqara Wall Switch D1 It looks like this:

L -----[SWITCH]----- L1 (to the lamp)




N ------[SWITCH]-------- (power module)

Once connected, carefully place the wires in the rosette so that they do not overflex and touch each other.

Step 4: Installation in the rosette and check

Make sure all wires are securely secured and do not fall out of the terminals.

  1. The keys must physically turn on/off the lights.
  2. The indicator on the switch (if any) must be lit or flashing.
  3. The device must emit an audible signal or flash when turned on (in some models).

If something doesn't work, turn off the machine right away and check if the wires are connected correctly. A common error is the entangled phase and zero, which causes the switch to not turn on.

What if the switch does not respond to the press?
If the keys do not work after connecting, check: 1. The correctness of the phase and zero connection (change them if you mixed them up). 2. The reliability of the wire attachment in the terminals (sometimes the wires do not reach the contact). 3. The presence of voltage in the network (possibly the automatic machine worked). 4. Compatibility of the switch with the type of lamps (some models do not work with the light switch) LED-low-power).

Setting up the switch in the Mi Home app

Once you've successfully connected, you need to add a switch to the Xiaomi ecosystem.

  1. Install the Mi Home app (available for Android and iOS).
  2. Register or log in to your account.
  3. Press + β†’ Add the device.
  4. Choose the category of Smart Home β†’ Switches.
  5. Follow the instructions on the screen (usually hold the button on the switch until the indicator flashes).

After the device has been added:

  • πŸ“± Name a switch (e.g., "Light in the hall").
  • πŸ“± Set up the room in which it is installed.
  • πŸ“± Check the work through the application (on/off).
  • πŸ“± If necessary, create automation (for example, turn off the light on a timer).

If the switch is not an app, try:

  • πŸ”„ Restart router (sometimes devices don’t connect due to network issues).
  • πŸ”„ Make sure the switch is in pairing mode (flashing the indicator).
  • πŸ”„ Check if your router supports Zigbee protocol (for models on this protocol).

πŸ’‘

If you have a two-key switch, in Mi Home, it can appear as two separate devices, and you can combine them into a single group for synchronous control.

Integration with voice assistants and other devices

One of the benefits of Xiaomi's smart switches is the ability to control voice and create automation scenarios. Here's how to set it up:

Manage via Alice, Google Assistant or Siri

For voice control:

  1. In Mi Home, go to the switch settings.
  2. Select Voice Control.
  3. Connect your Xiaomi account to Yandex.Station, Google Home or Apple HomeKit (depending on the ecosystem).
  4. Say a command, such as, "Alice, turn on the light in the room."

If the voice assistant does not recognize the device, check:

  • πŸ”Š The correct name of the switch in Mi Home (without special characters).
  • πŸ”Š Availability of updates in the assistant appendix.
  • πŸ”Š Connecting Xiaomi account to the assistant service.

Creating automation

You can set up automatic scripts in Mi Home, for example:

  • ⏰ Schedule: Turn off the lights at 23:00.
  • πŸŒ“ Motion sensor: turn on the light when motion is detected.
  • πŸ”„ According to the state of the other device: turn off the lights if the curtains are closed.

To create automation:

  1. In Mi Home, go to Automation section.
  2. Click + β†’ Add automation.
  3. Select a condition (e.g. Time or Device).
  4. Select the action (on/off switch).
  5. Save the script.

An example of useful automation: If you leave home, all Xiaomi switches can be turned off with a single button through No One Mode.

Common Mistakes and How to Avoid Them

Even with careful installation, you can make mistakes that will cause the switch to fail or even damage the wiring, and here are the most common ones:

⚠️ Warning: If the switch warms or smells of burning after it's connected, immediately disconnect it from the mains! This is a sign of short circuit or overload. Check the correct connection of the wires and the integrity of the insulation.

Mistake.Effects of consequencesHow to fix it
Phase and zero are confused.The switch does not turn on or does not work correctly.Swap wires in the terminals
Weak contact in the terminalsLight flickering, heating the switchReconnect the wires, tighten the screws.
There's no zero in the rosette.The switch is not switched on, there is no communication with Mi HomeStrip zero from the socket or use a model without zero
Use of the LED-low-powerLights flickering, spontaneous switching onInstall a ballast resistor or use power lamps >10 Watts.

Another common problem is that the switch is running, but it's not connecting to the Mi Home.

  • πŸ“Ά Weak Wi-Fi or Zigbee signal (move router closer or use repeater).
  • πŸ”„ Device not in pairing mode (hold the button 5-10 seconds until blinking).
  • πŸ”§ Incompatible firmware (update the Mi Home app and breaker firmware).

If nothing works, try resetting the switch to factory settings, which usually requires holding the 10-15 second button until the beep is heard.

FAQ: Frequent questions about connecting Xiaomi switches

Can you connect Xiaomi smart switch without zero wire?
Most zero-enabled Xiaomi and Aqara models won’t work without it: πŸ”Œ Xiaomi Mi Wireless Switch – works without a wiring connection, but requires batteries. πŸ”Œ Aqara Mini Switch β€” mounted on top of a wall and operates smart lamps on Zigbee. If there is no zero in the rosette, you can stretch it from the nearest outlet or use a smart lamp instead of a switch.
Why does Xiaomi switch flash after installation?
The flickering may be caused: πŸ’‘ Use LED-low power lamps (install a ballast condenser or incandescent lamps). πŸ”Œ Unstable contact in the terminals (check the tightening of the screws). πŸ“‘ Firmware problems (update device via Mi Home) If flicker doesn't go away, try connecting the switch to another line (for example, via an extension cord for the test).
How to reset Xiaomi smart switch to factory settings?
To reset: Hold the button on the switch for 10-15 seconds. Wait for the beep or flash of the indicator (usually 3 times). Release the button - the device will reset. After reset, you need to re-introduce the switch to Mi Home.
Can you use a Xiaomi smart switch with conventional lights?
Yes, Xiaomi smart switches are compatible with most types of lamps: πŸ’‘ Filament lamps. πŸ’‘ Halogen lamps. πŸ’‘ LED-lamps (but with a power of at least 5-10 W, otherwise problems may occur) It is not recommended to connect a lamp switch with a total power of more than 1000-1500 W (check the maximum load in the instructions for the model).
What to do if the switch warms up after the connection?
Heating the switch is a dangerous sign that can lead to a fire. Causes and solutions: πŸ”₯ Weak contact - tighten the screws in the terminals. πŸ”₯ Overload – Reduce the number or power of lamps. πŸ”₯ Poor device – contact Xiaomi Service Center.If the heat does not disappear, do not use the switch until the problem is fixed!