Setting the screen lock time on Xiaomi: all the ways and nuances

The lock time on Xiaomi smartphones is one of those settings that directly affect the device’s usability and energy efficiency. Too short a time frame leads to constant unlocking, and too long to a quick battery drain. But not everyone knows that MIUI has several ways to change this setting, including hidden options for advanced users.

In this article, we will analyze all available methods: from standard settings in the menu to use. ADB-We'll focus on the nuances of different versions of the shell (MIUI 12/13/14) And we'll look at why the settings don't always work, and how to fix them. If you want to optimize the balance between convenience and battery savings, read on.

Why it is important to set the lock time correctly

The autolock interval not only affects the comfort of use, but also the battery life. AMOLED-Xiaomi 13 Pro, Redmi Note 12 Pro+) Even a black screen uses energy to keep the display active. LCD (POCO X5, Redmi 10C) The lighting is constantly running until the screen goes out.

In addition, incorrect settings can cause problems:

  • πŸ”‹ Accelerated battery discharge – if the screen locks after 30 seconds but you use it often, the system wastes energy on constant unlocking.
  • πŸ”’ Risk of accidental pressing - at a long interval (10)+ in the pocket can trigger taps, leading to unwanted actions (calls, purchases).
  • πŸ›‘οΈ Security vulnerability – if the phone stays unlocked for too long, the risk of data access increases when the device is lost.

The optimal time depends on the use scenario: for office work, 2-5 minutes will work, for an active messenger - 30 seconds, and for reading books or watching videos, it is better to set 10-15 minutes or turn off autolock altogether.

πŸ“Š What time of locking the screen you use?
30 seconds
1 minute
2 minutes.
5 minutes.
10 minutes or more
Disconnected.

Standard method: change through MIUI settings

The easiest method is to use the built-in shell settings. It works on all modern Xiaomi smartphones, including Redmi, POCO and Black Shark, regardless of the MIUI version (starting with the 10th).

  1. Open the Settings app (cog icon).
  2. Go to the Screen section (or the Display on some models).
  3. Select Sleep mode (in some firmware – Autolock or Timeout screen).
  4. Set the desired interval from the available options: from 15 seconds to 30 minutes or Never.

On some devices (e.g. Xiaomi 12T or POCO F5), the path may be slightly different:

Settings β†’ Display β†’ Additional β†’ Sleeping mode

If your menu doesn’t have Sleep Mode, try searching by settings (the magnifier icon at the top of the screen) and enter the β€œaut-lock” or β€œtime-out” request.

Put your phone on charge (recommended for low battery charge)

Close all background applications

Make sure that the developer mode is enabled (if you plan to use ADB)

Check the version. MIUI under the heading β€œOn the telephone"-->

Advanced settings through the developer mode

In some cases, standard options are limited (for example, maximum time is 10 minutes) and to access additional intervals, you need to activate the developer mode:

  1. Go to Settings. β†’ The phone.
  2. Find the MIUI version and tap it 7 times in a row until the notification β€œYou’ve become a developer!” appears.
  3. Return to the main settings menu and open a new Developer section (usually at the bottom of the list).
  4. Find the option Sleep mode when connecting to charging – here you can set a separate lock time when the phone is charging.

This menu is also available:

  • πŸ”„ Disabling sleep when active content is present (for example, while watching a video).
  • πŸ”Œ Configure the behavior of the screen when connecting to Power Bank (different from network charging).
  • πŸ“± Ignoring the proximity sensor (useful if the screen goes out during calls).
What to do if the developer mode is not activated?
If so, 7 press MIUI" Nothing's happening, try it: 1. Reboot the phone. 2. Check if a password/pattern lock is set (without it, the mode is not activated). 3. Update the firmware to the latest version (in older versions) MIUI Could be bugs). 4. Use an alternative method: connect your phone to your PC and execute the command adb shell settings put global. development_settings_enabled 1

Change in the time of blocking through ADB (for experienced users)

If you don't like the standard settings (like setting a time of 1 hour or 5 seconds), you can use ADB, the Android debugging tool, which requires a computer connection and basic command line knowledge.

Here's how to do it:

  1. Install Platform Tools on PC (or use Minimal ADB and Fastboot).
  2. Activate debugging over USB in the developer settings.
  3. Connect your phone to your PC and execute the command: adb shell settings put system screen_off_timeout 60000 where 60000 β€” millisecond (60 000 miss = 1 For a minute. 5 use a minute 300000, for 30 seconds β€” 30000.
  4. Restart the device so that the changes take effect.

Note: on some models (e.g. Xiaomi 13 Ultra with MIUI 14) after updating the system, the ADB settings may be reset.

adb shell settings put global screen_off_timeout_custom 1


adb shell settings put global screen_off_timeout 60000

πŸ’‘

If, after the execution, ADB-The lock time has not changed, check if it is blocked by a third-party application (for example, "Saving charge" or "Security.

Problems and Solutions: Why Settings Are Not Saved

Sometimes users experience lock times reset after rebooting or updating, and here are common reasons and ways to fix them:

Problem.Possible causeDecision
Settings are reset after rebootingConflict with MIUI optimizer or Security applicationAdd ADB command to autoboot or disable optimization for system applications
There is no "Sleep Mode" option on the menuOutdated version of MIUI or custom firmwareUpdate your firmware or use ADB
Lock time is ignored when connecting to chargingActive setting "Do not turn off the screen when charging"Turn it off in developer mode or through ADB
The screen goes out in 5 seconds despite settingsUltra-low consumption mode or "Black Screen" is activatedCheck the battery settings and turn off energy saving modes

If the problem persists, try resetting the screen settings to factory:

adb shell settings reset system screen_off_timeout

πŸ’‘

On devices with MIUI 14 newer ADB-And if you can block teams, you can block them by security policies, and if you do, you can install a custom Recovery (TWRP) file editing /system/build.prop.

Features for different Xiaomi models

The manufacturer often makes interface changes for different product lines, and here are the key differences:

  • πŸ“± Redmi and POCO (Budget models: usually have a simplified menu with no additional options in developer mode. Maximum lock time is 10 minutes.

For example, on the POCO F4 GT, when you activate the game mode (Settings β†’ Special features β†’ Game turbo mode), the screen does not lock, even if you set a short timeout. And on the Xiaomi Pad 6 you can configure separate rules for horizontal and vertical orientation.

πŸ’‘

On smartphones with MIUI 13 and later, the Adaptive Lock option appeared in the screen settings, and if it's on, the system automatically adjusts the time based on the user's activity, and turn it off if you want to fix the interval rigidly.

Alternative methods: applications and automation

If the built-in settings don't work, you can use third-party tools. Here are the proven options:

  • πŸ€– Tasker: allows you to create lock rules based on time of day, location or connected devices, such as a 30-second timeout at work and a 10-minute timeout at home.
  • ⏱️ Keep Screen On: A simple app that keeps the screen on while a particular app is running (e.g. YouTube or Chrome).
  • πŸ”„ MacroDroid: Automates the change of lock time on schedule or when conditions are met (for example, when connecting to the Wi-Fi network Home").

When using third-party applications, consider:

⚠️ Note: Some programs (such as Keep Screen On) may conflict with system optimizers. MIUI. After installing them, add the application to the exception list in the battery settings (Settings) β†’ Battery β†’ Optimizing the battery).

For Tasker, you will need a one-time setting:

  1. Create a new task (Task β†’ New Task).
  2. Add the Display action β†’ Display Timeout.
  3. Specify the time in seconds (for example, 300 for 5 minutes).
  4. Save and activate the task.

FAQ: Answers to Frequent Questions

Can I set a lock time of more than 30 minutes?
In standard settings MIUI maximum β€” 30 To set more, for example, 1 hour), use ADB-Adb shell settings put system screen_off_timeout 3600000 or third-party applications like Tasker.
Why is the screen locked after 5 seconds, even though it is set for 1 minute?
This is a typical problem when you activate ultra-low consumption mode or the Black Screen function in the battery settings. Turn them off in Settings β†’ Battery β†’ Power modes.
How to turn off the screen lock altogether?
Select the option Never in the sleep settings. If it's not, use it. ADB: adb shell settings put system screen_off_timeout 2147483647 Important (2 147 483 647 ms) ~24 And in some days, it basically turns off timeouts, but remember, the constant operation of the screen reduces the resource. AMOLED-matrix.
Will you reset your settings if you update MIUI?
With a normal update (via Settings β†’ System Update), the screen settings will remain, but with a full reset (wipe) or manual firmware via Fastboot, all settings will return to factory settings.
Can I set different lock times for different applications?
Yes, but only with third-party tools: Tasker β€” create a profile with the condition "Application is running" and action "Display Timeout." Stay Alive β€” allows you to flexibly configure the rules for each application. MIUI no such function.