Why Wi-Fi Turns Off When You Lock Your Phone: A Complete Analysis of Causes and Solutions

Have you noticed that your internet connection disappears immediately after locking your smartphone? This problem is familiar to many users. Android And iPhone — Wi-Fi suddenly disconnects, and apps stop syncing in the background. As a result, notifications aren't coming in, downloads are interrupted, and messaging apps only update after unlocking. Is this a system bug, battery-saving measures, or a router setting issue?

In practice, there are minimal reasons 7, and most of them can be fixed without calling a service center. In this article, we'll cover:

  • 🔋 Energy-saving functionsthat choke Wi-Fi in the background (and how to disable them).
  • ⚙️ Hidden Android/iOS settings, affecting the stability of the connection.
  • 📡 Problems with the router, due to which the phone loses the network when going into sleep mode.
  • 🛠️ Software glitches and methods for diagnosing them (including tests through ADB).

We will pay special attention to unique nuances for specific models (for example, why on Xiaomi And Samsung Wi-Fi behaves differently when blocked. and we'll dispel myths like "the router is to blame" or "you need to reset your phone to factory settings."

📊 How often does your Wi-Fi disconnect when you lock your phone?
Constantly
Sometimes
There was before, but not now.
Never noticed

1. Energy Saving: The Main Culprit Behind Wi-Fi Disconnections

In 80% of cases the problem lies in aggressive energy optimizationSmartphone manufacturers (especially Xiaomi, Huawei, Oppo) actively save battery life by pausing background processes, including Wi-Fi. When the screen is locked, the system can:

  • 🔌 Completely disable the Wi-Fi adapter (on budget models).
  • 📉 Reduce signal strength to minimum (on flagships).
  • ⏸️ Pause data synchronization (even if the indicator shows a connection).

On Android There are two functions responsible for this:

  1. Adaptive battery (enabled by default on Android 9+) - limits the activity of applications in the background.
  2. Charging optimization (in battery settings) - can turn off Wi-Fi when the battery level is low (even if the phone is charging!).

On iPhone the regime plays a similar role Battery Saver (Settings → Battery), which automatically activates when the battery reaches 20%. In this mode, iOS suspends background activity, including checking email and updating apps over Wi-Fi.

⚠️ Attention: On some models Samsung (series A5x, A7x) there is a hidden function Auto Hotspot Switch, which forces the phone to switch to mobile data when locked, even if Wi-Fi is on. It must be disabled separately in Settings → Connections → Mobile networks → Auto-switch Wi-Fi.

2. Wi-Fi settings in sleep mode: what to check first

AND Android, And iOS Allows you to flexibly configure Wi-Fi behavior when the screen is locked. Most often, the problem is solved by changing one or two settings:

Parameter Where is it located? Recommended value
Connect to Wi-Fi in sleep mode Settings → Wi-Fi → Advanced → Connect to Wi-Fi in sleep mode Always (not "Only when connected to charging")
Wi-Fi scanner in sleep mode Settings → Location → Wi-Fi Scanner Included (otherwise the phone will not "see" the networks)
Background data transfer Settings → Apps → [Select app] → Mobile data & Wi-Fi Allow background transfer for key applications (messengers, mail)
Modem mode Settings → Connections → Tethering Disable (may conflict with Wi-Fi)

On iPhone Similar settings are hidden deeper:

  1. Go to Settings → Wi-Fi and click on the "i" symbol next to your network.
  2. Make sure the switch is on "Connect automatically".
  3. IN Settings → General → Content Update Check that for key applications (eg. WhatsApp, Telegram) Wi-Fi update is enabled.

Disable power saving mode|Set "Connect to Wi-Fi in sleep mode = Always"|Check background data transfer for instant messaging apps|Update your router firmware|Restart your phone and router-->

3. Router Problems: Why Your Phone Loses Network

If your phone settings are fine, but Wi-Fi still turns off, it's your fault. routerHere are typical scenarios:

  • 🔄 DHCP interval too short — the router "forgets" the phone after 5-10 minutes of inactivity and assigns its IP to another device.
  • 📶 Weak signal at the edge of the coverage area — the phone loses connection at the slightest signal deterioration (for example, if it is placed face down).
  • Router energy saving - some models (for example, TP-Link Archer C6) reduce transmitter power at night.

How to check:

  1. Connect your phone to a different Wi-Fi network (for example, at a cafe or at a friend's place). If the problem goes away, your router is to blame.
  2. Look at the router logs (192.168.0.1 or 192.168.1.1 in the browser) for phone authentication errors.
  3. Try connecting to the router at a frequency 5 GHz instead of 2.4 GHz (or vice versa) - some phones have poor communication on one of the frequencies.
⚠️ Attention: If you have a dual-band router and your phone only supports 2.4 GHz (for example, older models iPhone 5/SE), when blocked, it can "lose" the network due to the router automatically switching to 5 GHzSolution: Bind your phone to a fixed frequency in your router settings.
How to check if your phone supports 5GHz?

Open the list of available Wi-Fi networks. If you see names with the suffix _5G or -5GHz, your phone supports this frequency. If not, just 2.4 GHz.

4. Software failures: when firmware or applications are to blame

Sometimes Wi-Fi disconnects due to software conflictsTypical reasons:

  • 🤖 Bugs in Android firmware - especially relevant for custom shells (MIUI, One UI, ColorOS).
  • 📱 Google Play Services issues (on Android) or iCloud (on iPhone).
  • 🔄 Conflict with VPN or firewall - some applications (for example, 1.1.1.1 or AdGuard) block background activity.

How to diagnose:

  1. Start your phone in safe mode (on Android: hold down the power button → "Safe mode"; iPhone(When turning on, hold down the volume up button.) If Wi-Fi is stable, a third-party app is to blame.
  2. Check the system logs via ADB (For Android):
    adb logcat | grep -i "wifi\|dhcp\|connect"

    Look for lines with errors like WifiStateMachine: Disconnecting or DhcpClient: Failed to renew.

  3. Update your phone and router firmware to the latest version (especially if you are using beta versions).

For iPhone It is useful to reset network settings:

  1. Go to Settings → General → Transfer or reset iPhone → Reset → Reset Network Settings.
  2. After the reset, reconnect to Wi-Fi and check if it works in the background.

5. Features of specific brands: Xiaomi, Samsung, iPhone

Manufacturers often add unique features, which affect Wi-Fi performance. Let's look at the most problematic ones:

Xiaomi (MIUI)

  • 🔋 Deep battery optimization — even after disabling power saving in the settings, Wi-Fi may still disconnect. Solution: Settings → Apps → Manage apps → [Three dots] → Special permissions → Battery optimization disable optimization for everyone network-related system applications.
  • 📡 Automatic switching to mobile data - V Settings → SIM cards and mobile networks → Auto-switch Wi-Fi Disable this feature.

Samsung (One UI)

  • Adaptive Energy Saving - can turn off Wi-Fi if the phone is not moving. It turns off in Settings → Device care → Battery → Advanced → Adaptive power saving.
  • 🔄 Conflict with Knox - if you use a work profile (Samsung Knox), it may block background activity. Check the settings in Settings → Biometrics & Security → Knox.

iPhone (iOS)

  • 📱 "Wi-Fi Assist" - automatically switches to mobile data when the Wi-Fi signal is weak. Disables in Settings → Cellular → Wi-Fi Assist.
  • 🔒 Privacy Limitations - if in Settings → Privacy → Location Services → System Services disabled Network Geofences, iPhone may lose connection.

6. Hardware problems: when the Wi-Fi module is to blame

If all software methods have been tried, but Wi-Fi still turns off, it is possible hardware failureTypical symptoms:

  • 🔌 Wi-Fi turns off even when the charger is connected.
  • 📉 The signal disappears with the slightest movement of the phone (for example, if you pick it up in your hand).
  • ⚡ The phone overheats in the antenna area (upper left corner).

What to check:

  1. Antenna condition If the phone was dropped or got wet, the antenna contacts may have oxidized. At the service center, this can be cleaned using ultrasonic cleaning.
  2. Wi-Fi module - on older phones (for example, iPhone 6/7, Samsung Galaxy S7) it may fail due to overheating.
  3. Battery - If the battery is swollen, it can put pressure on the motherboard and cause Wi-Fi problems.

For diagnostics:

  • Connect your phone to Wi-Fi and call it from another device. If the connection is stable during the call, the problem is with the Wi-Fi module.
  • Check your Wi-Fi connection modem mode (Internet sharing). If other devices connect normally, the problem is in your phone's software.
⚠️ Attention: On phones with supported eSIM (For example, iPhone XS and newer) Wi-Fi outages may be due to a conflict between the physical SIM card and the virtual one. Try temporarily removing eSIM-profile.

7. Alternative solutions: if nothing helps

If all the above methods didn't work, try:

  • 🔄 Reset network settings (do not confuse with a full reset of the phone!):
    • On Android: Settings → System → Reset → Reset Wi-Fi, mobile network, and Bluetooth settings.
    • On iPhone: Settings → General → Transfer or reset iPhone → Reset → Reset Network Settings.
  • 📱 Using third-party applications to control Wi-Fi, for example:
    • WiFi Manager (Android) - allows you to record your network connection.
    • NetGuard - Blocks background activity from other apps that may interfere with Wi-Fi.
  • 🔧 Manual IP assignment (if the problem is in the router's DHCP):
    • In the Wi-Fi network settings, specify a static IP (for example, 192.168.1.100) and DNS (8.8.8.8).

The last resort is - phone firmware via official utilities:

  • For Samsung: Odin + stock firmware from the website sammobile.com.
  • For Xiaomi: Mi Flash Tool + firmware Fastboot.
  • For iPhone: recovery via iTunes/Finder (DFU mode).

FAQ: Frequently asked questions about disabling Wi-Fi when blocked

❓ Why does Wi-Fi only turn off at night?

Most likely, he is to blame. night power saving mode router or phone. Check:

  1. Router settings for scheduling Wi-Fi shutdowns (for example, "Parental Control" or "Power Saving").
  2. On the phone: Settings → Lock screen → Sleep mode (on Samsung) or Settings → Display & Brightness → Auto-Lock (on iPhone).

Also some firmware (for example, MIUI) aggressively optimize the battery at night. Try disabling "Night Optimization" in the battery settings.

❓ Can a virus cause Wi-Fi to disconnect?

Theoretically yes, but in practice it is unlikely. Viruses for Android Sometimes they block the internet to show ads, but they rarely target Wi-Fi specifically. You can check this:

  1. Install antivirus (Malwarebytes, Dr.Web) and scan the system.
  2. Check the list of installed applications for suspicious ones (especially those with rights) ADMIN or VPN).
  3. Start your phone in safe mode — If Wi-Fi works stably, third-party software is to blame.

On iPhone There are practically no viruses that affect Wi-Fi (due to the closed nature of iOS).

❓ Why does Wi-Fi work when charging, but turn off when on battery?

This is a classic sign. aggressive energy savingThe system assumes that charging doesn't conserve battery power, so Wi-Fi works fine. Solutions:

  • On Android: V Settings → Battery → Power saving mode Disable all Wi-Fi restrictions.
  • On iPhone: turn off Saving battery life (Settings → Battery).
  • Check your settings Adaptive battery (Android 9+) - it can suspend Wi-Fi when the battery level drops below 15–20%.

If it doesn't help, the problem is power controller phone (needs repair).

❓ How can I check if my Wi-Fi is actually disconnecting and not just "falling asleep"?

Use one of these solutions:

  1. Ping test:
    ping -t 192.168.1.1 > ping_log.txt

    Run the command on a PC connected to the same router and lock your phone. If timeouts appear in the log, the Wi-Fi is indeed disconnected.

  2. Monitor application:

    Install WiFi Analyzer (Android) or Network Analyzer (iOS) and enable signal logging.

  3. Notifications from the router:

    In the router settings (192.168.0.1) enable connection logs and check if the phone disconnection is registered.

❓ Will changing the router help?

Possibly, but not always. Changing your router makes sense if:

  • 📡 The current router is older than 5 years (outdated standards) 802.11n (doesn't work well with modern phones).
  • 🔄 The router frequently overheats or reboots spontaneously (check the logs).
  • 📱 Other devices (laptops, tablets) are connected to this router stably, but the problem is only with the phone.

If Wi-Fi disconnects on other networks as well, the problem is with your phone. Before buying a new router, try the following:

  1. Update the firmware of the current router.
  2. Turn it off on it WPS And QoS (they sometimes conflict with phones).
  3. Change the Wi-Fi channel to 6 or 11 (less busy).