Skip to main content

Overview

Opens OEM-specific battery or background settings if available for the current device. Many Android manufacturers implement aggressive battery optimization features that can kill apps even when standard Android battery optimizations are disabled.

Returns

success
boolean
Promise resolving to true if OEM settings were successfully opened, false if the device doesn’t have recognized OEM settings or if opening failed.

Platform Behavior

Why OEM Settings Matter

Standard Android battery optimization APIs are often insufficient. Many manufacturers add their own aggressive power management: Problem: Even with battery optimization disabled via isIgnoringBatteryOptimizations(), manufacturers’ custom systems may still kill your app. Solution: Guide users to whitelist your app in the manufacturer’s settings.

Supported Manufacturers

This method recognizes and attempts to open settings for:
  • Xiaomi (MIUI) - Autostart and battery settings
  • Samsung (OneUI) - Battery and app management
  • Huawei (EMUI) - App launch and protected apps
  • Honor - Startup manager
  • OnePlus (OxygenOS) - Chain launch management
  • Oppo (ColorOS) - Startup app list
  • Vivo (FuntouchOS) - Background startup manager
  • Realme (based on ColorOS) - Startup settings
  • Asus (ZenUI) - Autostart management
  • Lenovo - Background management
  • Meizu (Flyme) - Power permissions
  • Nokia (HMD Global) - Power saver exceptions
For unlisted manufacturers, it falls back to standard Android battery optimization settings.

Example Usage

Basic Usage

Check Manufacturer First

Manufacturer-Specific Instructions

Onboarding Flow

Troubleshooting Screen

Complete Setup Helper

With Fallback

Implementation Details

The method:
  1. Detects manufacturer using Build.MANUFACTURER
  2. Tries multiple known component intents for that manufacturer
  3. Falls back to standard battery optimization settings
  4. Falls back to app details settings
  5. Returns false if nothing could be opened

Testing

Since OEM settings vary by manufacturer: