A server backed key-value storage system available on Apple's iOS and OS X platforms meant for syncing data between devices.
Questions tagged [nsubiquitouskeyvaluestore]
68 questions
20
votes
3 answers
iCloud NSUbiquitousKeyValueStore initial sync/access delay - how to handle?
I'm using NSUbiquitousKeyValueStore to store some app settings. My logic is: when I save data locally, I save it to NSUbiquitousKeyValueStore also as a backup. When I need settings, I read locally and I only use iCloud key-value store if no data is…

Tertium
- 6,049
- 3
- 30
- 51
14
votes
2 answers
How to programmatically detect if the iCloud is enabled on user's device when only use NSUbiquitousKeyValueStore?
I am using NSUbiquitousKeyValueStore to sync some preference data to iCloud. I found that if the user disable "Document & Data" item of iCloud in "Setting App", NSUbiquitousKeyValueStore can not synchronize its data to iCloud. So, I want to first…

Jagie
- 2,190
- 3
- 27
- 25
11
votes
5 answers
NSUbiquitousKeyValueStore error: no valid com.apple.developer.ubiquity-kvstore-identifier entitlement
I'm having a problem integrating iCloud with my app.
When I set test out iCloud availability, I receive Success for the function
NSURL *iCloudURL = [fileManager URLForUbiquityContainerIdentifier:@"AppID"];
but right after this, when I attempt to…

Rich Byden
- 509
- 2
- 6
- 13
11
votes
1 answer
Can a user manually delete values in iCloud key-value storage NSUbiquitousKeyValueStore
I'm wondering if there is a way someone other than I (the developer) can delete values stored in NSUbiquitousKeyValueStore.
Documentation states that an app is given 1MB/1024 Key Value pairs. It does not mention if a user is able to delete them via…

Erik Kerber
- 5,646
- 7
- 38
- 56
10
votes
2 answers
NSUbiquitousKeyValueStore vs NSUserDefaults
From Apple's NSUbiquitousKeyValueStore documentation:
If you write to the key-value store object when the user is not signed into an iCloud account, the data is stored locally until the next synchronization opportunity. When the user signs into an…

David T
- 2,724
- 1
- 17
- 27
8
votes
3 answers
How to use NSUbiquitousKeyValueStore and NSUserDefaults together
Documentation is not clear on how to use NSUbiquitousKeyValueStore with edge cases.
If I want to set a value, I understand that I should set a value to both NSUserDefaults and NSUbiquitousKeyValueStore since iCloud could be disabled. However in my…

gcamp
- 14,622
- 4
- 54
- 85
8
votes
4 answers
NSUbiquitousKeyValueStore not syncing with iCloud
I've tried everything and read all topics, but I can't find out why NSUbiquitousKeyValueStore is not being stored on iCloud.
• Created a specific App ID
• Enabled iCloud to this App ID
• Created Provisioning Profile
• Enable iCloud on the Project
•…

tomDev
- 5,620
- 5
- 29
- 39
8
votes
1 answer
Wait for existing iCloud values before setting a value?
In my app, I need to share a setting between different devices running the app. I want the first device that install the app to set the master value of the setting, then all other devices should get that setting and not overwrite it.
How do I make…

thejaz
- 2,763
- 2
- 26
- 40
7
votes
1 answer
Is it safe to rely on NSUbiquitousKeyValueStore for storing essential data?
I learned that NSUbiquitousKeyValueStore is always available, also when no iCloud account is set up. This makes me believe I can safely store essential data in it, without keeping a copy in NSUserDefaults.
However, in their documentation, Apple says…

Jonathan
- 6,572
- 1
- 30
- 46
7
votes
5 answers
Deleting iCloud data doesn't clear out NSUbiquitousKeyValueStore?
I have an app that is configured to use iCloud. I am adding a key/value to the NSUbiquitousKeyValueStore and I can retrieve it as expected across all of my devices. However, if I delete my app's iCloud data from under Settings, I would expect that…

lehn0058
- 19,977
- 15
- 69
- 109
7
votes
6 answers
NSUbiquitousKeyValueStore sync issues
I'm having nothing but trouble with NSUbiquitousKeyValueStore and getting it to reliably sync across two devices. It's starting to drive me mad. Mad.
I watch my code make a call to:
[[NSUbiquitousKeyValueStore defaultStore] setObject:_someData…

Roger Gilbrat
- 3,755
- 5
- 34
- 58
6
votes
3 answers
How to handle first time launch experience when iCloud is required?
I am using CloudKit to store publicly available data and the new NSPersistentCloudKitContainer as part of my Core Data stack to store/sync private data.
When a user opens my app, they are in 1 of 4 states:
They are a new user with access to…

PointOfNilReturn
- 416
- 4
- 13
6
votes
1 answer
Any way to determine size of iCloud key value storage to ensure it's < 1MB?
Is there a way to determine how much of the 1MB allotted an app is using for iCloud KVS? i checked the settings>iCloud route, but I don't think if it's KVS it shows up there. I'm just storing an array of some strings, but just wanted to see what…

skinsfan00atg
- 571
- 1
- 3
- 19
6
votes
4 answers
Proper handling of NSUbiquityKeyValueStore updates across devices?
My app stores a single key-value pair in iCloud using NSUbiquityKeyValueStore, an array of objects. The entire array is saved to iCloud when a change is made to any object in the array. This works great as long as each device has an opportunity to…

Michael Mangold
- 1,741
- 3
- 18
- 32
5
votes
1 answer
What is the NSUbiquitousKeyValueStore equivalent for watchOS?
App Groups is sadly not supported on watchOS still and NSUbiquitousKeyValueStore is available for every platform except watchOS. I've read the Keeping Your watchOS Content Up to Date and mentions iCloud and they make it sound so easy but don't…

TruMan1
- 33,665
- 59
- 184
- 335