How to close application using button ionic

I just want to add a few notes to the following answer:

  • An additional Cordova plugin might be needed:

navigator.app.exitApp() does not work on iOS, only Android. On iOS, Apple does not allow apps to programmatically exit. It can be done through iOS Objective-C side but there’s a good chance this app will be rejected in Apple app store.

  • Therefore, I would not recommend you to do it and to rethink your UI instead:
3 Likes