Try “Xiaomi 14”, “marble”, “Redmi Note 13” or “OS2.0”

Xiaomi 18 Fold
HyperOS 4.0StableChina

Xiaomi 18 Fold HyperOS 4.0 OS4.0.21.0.XPNCNXM

Stable firmware for the China Xiaomi 18 Fold (lhasa), released September 26, 2026.

Download OS4.0.21.0.XPNCNXM

Recovery ROM (OTA .zip) · 9.7 GB Install from the phone’s updater app — keeps your data.
MD5: 053d7485701c573086f1ea7b611c0f1a
Download
Fastboot ROM (.tgz) · 12.7 GB Full image for Mi Flash Tool — clean install, unbrick or downgrade.
MD5: d9d00ff0717261a9f7cbc74e93d9b002
Download

Files are served from Xiaomi’s official servers. Compare the MD5 checksum after downloading to make sure the file is complete and untouched.

Firmware details

Device
Xiaomi 18 Fold
Codename
lhasa
Region
China
Version
OS4.0.21.0.XPNCNXM
OS
HyperOS 4.0
Android
17.0
Branch
Stable
Released
Sep 26, 2026
Package
Recovery 9.7 GB / Fastboot 12.7 GB

How to install OS4.0.21.0.XPNCNXM

Recovery ROM (recommended, keeps data)

  1. Back up your important data and charge the phone to at least 50%.
  2. Download the Recovery ROM above on your Xiaomi 18 Fold.
  3. Open Settings → About phone and tap the HyperOS version card.
  4. Tap the ⋮ menu → Choose update package and select the downloaded .zip file.
  5. Wait for verification, then tap Reboot now. The update takes 10–20 minutes.

Fastboot ROM (clean install, needs unlocked bootloader)

  1. Make sure the bootloader is unlocked and install Mi Flash Tool plus the Xiaomi USB drivers on a Windows PC.
  2. Download and extract the Fastboot ROM (.tgz) to a short path such as C:\rom.
  3. Power off the phone, hold Volume Down + Power to enter Fastboot mode and connect it via USB.
  4. In Mi Flash Tool select the extracted folder, choose clean all (wipes data) and avoid “clean all and lock” unless you want to relock.
  5. Click Flash and wait until the tool shows success; the phone reboots automatically.

Other Xiaomi 18 Fold (China) builds

Device page →
DeviceVersionAndroidBranchReleased
Xiaomi 18 FoldChina · lhasaOS4.0.5.0.XPNCNXM
HyperOS 4.0Stable Beta
17.0Stable Beta

Frequently asked questions

Is OS4.0.21.0.XPNCNXM an official Xiaomi 18 Fold update?
Yes. OS4.0.21.0.XPNCNXM is an official Stable HyperOS 4.0 build for the Xiaomi 18 Fold (China), released by Xiaomi on September 26, 2026. The download links point directly to Xiaomi’s update servers.
Which Android version does OS4.0.21.0.XPNCNXM use?
This firmware is based on Android 17.0.
Will installing OS4.0.21.0.XPNCNXM erase my data?
Installing the Recovery package through the updater app keeps your apps and data. Flashing the Fastboot package with “clean all” wipes the phone — back up first.
Can I install this on another region’s device?
Only install firmware that matches your device’s region (China) and codename (lhasa). Cross-region flashing requires an unlocked bootloader and can cause problems.