Yes, you can do something in the background. You are limited to several different background execution modes. Communication with the server is one of the modes that are allowed (background selection). Make sure that you have correctly configured the properties in Xcode in accordance with the recommendations (i.e. do not say that you are an audio application when transferring data). See here for more details:
https://developer.apple.com/library/ios/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/BackgroundExecution/BackgroundExecution.html
I found your question because it has a Cordova tag associated with it. If you use Cordoba, you can use this plugin here to manage things in the background:
https://github.com/katzer/cordova-plugin-background-mode
Edit: If the user closes / closes the FORCE application, then you can do nothing. If they just exit the application on the main screen and use other applications, you can work in the background.
Another option you can do is schedule a local notification to download the file. If the application successfully downloads the file because it is open / has a connection / did it in the background, you will cancel the local notification.
If the local notification is not canceled, it will remind the user that the file is not downloaded, and when they open the notification, your application will start working where it was stopped.
source share