Last Active
  • Video: Stop force closing all apps on your iPhone, it's a waste of time

    I agree with some prior comments, what is said in this video is untrue. Many apps run background processes which are killed off if you manually remove them from the active list (although some like Facebook run no matter what you).
    Can you please provide some examples of background processes that apps run?  Audio can be one, but that one's pretty obvious.  What other processes are my apps running in the background and how long do those processes run?  Thanks!
    Sure thing! An app is allowed to run in the background (for non-trivial amounts of time) for the following types of tasks:

    1. Audio, AirPlay, and Picture-in-Picture
    2. Location updates (eg, mapping) but only if it asks for location updates "always" instead of "when in use". (By the way, "always" actually means when the app has been launched and is still running in the background; if you force-close the app, then it no longer gets location updates. I think they should reword "always" to mean "if in foreground or background" and reword "when in use" to mean "only when in the foreground".)
    3. Voice over IP
    4. Newsstand downloads
    5. External accessory communication
    6. Uses Bluetooth LE accessories
    7. Acts as a Bluetooth LE accessory
    8. Background fetch (the app will be "woken up" every now and then so it can download any info it needs from the Internet)
    9. Remote notifications (a remote / "push" notification can be sent that will let the app run for a short time in the background)

    Note that these aren't simply loopholes; the apps have to actually use that feature. For example, if an app provides voice over IP, it can run in the background when handling a call. But when the call ends, the app goes to sleep again. (It gets woken up by iOS when a new call comes in.)

    In addition, all apps run for a very short time (up to ~10 seconds) when they are put into the background, so that they can save their state / data. If they need extra time (eg, to finish a large download), they can request a little more time; in iOS 10 this tends to be around 179 seconds in my testing. But they have to actually do something during that time, and can't simply go into a loop requesting another 179 seconds.

    Beyond that, answers #25 (by Xmcgraw) and #31 (by Randominternetperson) have a good overview of memory management.

    To flesh out a related topic: when you put an app into the background, it has a short time (~10 seconds) to save its "state." As stated in answer #25, when you bring it back into the foreground, it will restore its state, so it looks to you like it is still running, even though it may have been completely removed from memory if iOS needed to do so. (But you have no way of knowing if this happened, and you really don't care.) A caveat is that if you manually force-close an app, then the last saved state information is deleted, so the next time you launch the app it will launch from a "clean" state. This may be useful sometimes if the app has subtle bugs in its state saving / restoration code.