The proximity sensor on Xiaomi smartphones is a useful feature that automatically turns off the screen when you hold the phone to your ear. However, sometimes it malfunctions: the screen does not go out when you talk, buttons are accidentally pressed, or, conversely, the sensor works for no reason, blocking the display at the most uncomfortable moments. If you encounter such problems or just want to manually control the behavior of the screen, turning off the sensor can be the solution.
In this article, we will analyze all the current ways to deactivate the proximity sensor on Xiaomi, Redmi devices, POCO Black Shark โ from standard settings to methods for power users (including: ADB We will pay special attention to the nuances for different versions. MIUI (12-14) and the potential risks of each method, and let's warn you right away: some actions can affect the stability of the phone, so make a backup copy of the data before experimenting with the engineering menu or root rights.
Why does the proximity sensor interfere?
Before we go to shutdown, we need to understand where the sensor actually causes an inconvenience.
- ๐ False positives: The screen goes out in normal use (for example, when you hold the phone in your hand at an angle).
- ๐ Screen freeze: After ringing, the display does not turn on until you restart the device.
- ๐ฎ Problems in games: the sensor locks the screen when tilting the smartphone (relevant for Black Shark).
- ๐ง Incompatibility with cases: thick or metal covers can shield the sensor signal.
- ๐ ๏ธ Hardware malfunctions: after falling or getting moisture, the sensor does not work correctly.
If you see at least one of these symptoms, turning off the sensor can improve the user experience. However, keep in mind that without it, the screen will not automatically lock during calls, which can lead to accidental taps.
Method 1: Disconnect via standard MIUI settings
The easiest and safest method is to use built-in options. MIUI. Unfortunately, not all Xiaomi devices have this feature directly available, but it is worth checking. MIUI 12โ14:
- Open the Settings app.
- Go to the Screen section (or the Display on some models).
- Scroll down and find the Approach Sensor or Automatic Screen Shutdown.
- Move the slider to the off position.
If there is no such item, try an alternative path:
- Go to Settings โ System and device โ Additional settings.
- Find the Special Opportunities (or Convenience) section.
- Turn on the option to turn off the screen when approaching and immediately turn it off โ sometimes this resets the sensor settings.
Make sure the problem is not in the case (remove it)
Reboot the phone.
Update MIUI to the latest version
Try calibrating the sensor (see the next section)-->
On some models (Redmi Note 10 Pro, POCO X3 Pro) the option is hidden deeper. If you do not find it, move on to the next method.
โ ๏ธ Attention: On devices with MIUI Global and MIUI Europe can take a different path to settings. If you have custom firmware (e.g. Xiaomi.eu), look for Proximity sensor under Display settings.
Method 2: Calibration of the proximity sensor (alternative to disconnect)
Before you deactivate the sensor completely, try calibrating it, which can solve the problem of false positives without losing functionality.
- Open the Phone app.
- Enter the combination: ##6484### (some models run ##4636##).
- Select Proximity Sensor (Proximity Sensor).
- Press Calibrate and follow the instructions on the screen (usually close the sensor with your hand and then remove it).
If the combination doesnโt work, try these alternative codes:
- #64663## - Sensor test (select Proximity).
- ##0*## is a general display test (check the sensor response to the approach of the hand).
| Xiaomi model | Working code of the engineering menu | Notes |
|---|---|---|
| Redmi Note 11/12 | ##6484## | Menu in English, Proximity item at the bottom of the list |
| POCO F4/F5 | ##4636## | Select Sensor Test, then Proximity |
| Xiaomi 12/13 | ##64663## | Requires confirmation via volume button |
| Black Shark 5 | ##0*## | The sensor test in the Hardware Test section |
Once you've calibrated, restart your phone and check the sensor. If you have a problem, go to radical methods.
๐ก
If the engineering menu does not open, try entering codes through the Calculator app (type a sequence of numbers and symbols, as on your phone).
Method 3: Disconnect via ADB (without root)
If the standard settings don't work, you can turn off the sensor using Android Debug Bridge (ADB), which does not require root permissions, but requires a computer and a little preparation.
- Turn on USB Debugging on your phone: Go to Settings โ About Phone. 7 times click on MIUI Version to activate Developer Mode. Return to Settings โ Additional โ Developer. Activate USB Debugging.
ADB Tools
File transfer
Open the command prompt (Windows) or terminal (Mac/Linux) in the folder with ADB.
adb devices(Your device should appear)
adb shell settings put global proximity_sensor_enabled 0Reboot the phone.
To get the sensor back to work, use the command:
adb shell settings put global proximity_sensor_enabled 1โ ๏ธ Attention: On some firmware MIUI (This command may not work due to manufacturer limitations. In this case, try an alternative method:
adb shell settings put secure proximity_sensor_calibration 0,0,0,0,0,0,0,0,0,0,0,0This command resets the sensor calibration, which sometimes leads to its deactivation, but such an intervention can cause other sensors to malfunction (for example, light or gyroscope), so use it only if other methods did not help.
๐ก
ADB-Temporary commands โ after resetting settings or updating MIUI sensor can be activated again.
Method 4: Using applications to disable the sensor
If you don't want to mess with ADB, you can use third-party apps, which are suitable for non-root devices, but require USB Debugging enabled.
- ๐ฑ Proximity Sensor Reset - resets the sensor settings and allows you to disable it at the system level.
- ๐ ๏ธ Sensor Disabler is a universal application for deactivating any sensors (requires) ADB-access).
- ๐ง MIUI Hidden Settings โ reveals hidden options MIUI, It doesn't work on all versions.
Instructions for Proximity Sensor Reset:
- Install the application and open it.
- Press Reset Proximity Sensor.
- Go to Advanced and select Disable Proximity Sensor.
- Confirm the action and restart the phone.
For Sensor Disabler:
- Connect your phone to your PC and activate Debugging via USB.
- In the app, select Proximity Sensor from the list.
- Click Disable and confirm via ADB-connection.
โ ๏ธ Note: Apps from unverified sources may contain malicious code, download them only from Google Play or the official Xiaomi website. MIUI settings may reset.
Method 5: Disconnecting through root access (for power users)
If none of the previous methods worked, the radical solution is to turn off the system-level sensor using root rights, which is 100% effective, but has risks:
- ๐จ Loss of warranty (if the phone is under warranty).
- ๐ Risk of disrupting the system in case of incorrect actions.
- ๐ Reconfiguring after updates.
If you are ready for this, follow the instructions:
- Get root access on your Xiaomi (for example, through Magisk).
- Install a file manager with root support (such as Root Explorer or Solid Explorer).
- Go to /system/usr/keylayout.
- Find the Generic.kl file (or qrd_skuh.kl for some).
- Open the file in the text editor and find the line with proximity.
- Comment on it by adding a # symbol (example: #key 213 PROXIMITY) to the beginning.
- Save the changes, set the rights 644 (rw-r-----).
- Reboot the phone.
Alternative method through Magisk:
- Install the Disable Proximity Sensor from the Magisk repository.
- Activate the module and restart the device.
Once disabled, the sensor will no longer affect the screen, but you will lose automatic locking during calls.To return the feature, delete the changes to the Generic.kl file or deactivate the module in Magisk.
What to do if the root phone stops loading?
What to do if the sensor does not turn off?
If none of these things work, the problem could go deeper.
| Problem. | Possible cause | Decision |
|---|---|---|
| The sensor does not turn off through settings | Firmware restrictions (e.g. MIUI China) | Install a European or Global version of MIUI |
| ADB-teams are not working | Blocking by MIUI (starting with version 13) | Use Shizuku to bypass restrictions |
| After the switch is off, the sensor is activated again. | Automatic update of settings | Turn off automatic optimization in Settings โ Battery |
| Sensor physically damaged | Fall, moisture, wear and tear | Replacement of sensor in the service center (cost) ~1000โ2000 โฝ) |
If you suspect a hardware malfunction, check the sensor with tests:
- Install the Phone Doctor Plus or Sensor Test app.
- Run the proximity sensor test.
- If the value does not change when the sensor is closed with the hand (there is 5.0 cm left), the sensor is defective.
On some models (Xiaomi 13 Ultra, Redmi) K60 Pro) the proximity sensor is integrated into the display module, in which case it will cost more to replace, up to 5000-7000 โฝ.