Prevent iCloud backup of Phonegap’s localstorage

In a defalt setup (Phonegap 2.8.1), localstorage is marked for backup to iCloud. This may get your app rejected by Apple, depending on the size with the following rejection motivation:

The iOS Data Storage Guidelines indicate that only content that the user creates using your app, e.g., documents, new files, edits, etc., should be backed up by iCloud.

To prevent this to happen you can use the BackupWebStorage option in config.xml file. You can set BackupWebStorage to “none” or “local

To verify how much data the app is storing Apple suggests the following procedure:

  • Install and launch your app
  • Go to Settings > iCloud > Storage & Backup > Manage Storage
  • If necessary, tap “Show all apps”
  • Check your app’s storage
Facebooktwittergoogle_plusredditpinterestlinkedinmail