title: Android - How to Enable Autostart option programmatically in Xiaomi devices?
body: <p>I am developing an android application in which I want to display the Push notification.</p>
  
  <p>It has displayed well in most of the devices except <strong>Xiaomi</strong> phones (I am using Redmi Note 4). The problem that I found is, it is because of <strong>Autostart</strong> option provided by Xiomi which will be disabled by default and the user need to enable it manually.</p>
  
  <p>But I wonder that some of the Android Apps I could see enabling this option without any user interaction Ex: WhatsApp. If I try reinstalling WhatsApp and see the Autostart option , it is enabled!</p>
  
  <p>I am unable to convince our client by telling it is the feature of Xiomi like devices as he is pointing out some apps which is working fine like the example I have mentioned above.</p>
  
  <p>This question has been asked by some other people </p>
  
  <p><a href="https://stackoverflow.com/questions/41791150/add-my-app-to-autostart-apps-list-in-android-programmatically">Add my app to AutoStart apps list in android programmatically</a></p>
  
  <p><a href="https://stackoverflow.com/questions/43212113/how-to-check-autostart-is-enabled-for-our-app-in-xiaomi-manufacturer-mobile-devi">How to check AutoStart is enabled for our App in Xiaomi manufacturer mobile device Programmatically</a></p>
  
  <p>But I could not see any answers for them and Posting here with the hope that someone will have an answer for this.</p>