Software⏱️ 3 min read📅 2026-06-04

How to Fix: Failed to read values in CFPrefsPlistSource iOS 10

CFPrefsPlistSource issue in iOS 10, failed to read values from user defaults.

Quick Answer: Update to the latest version of Xcode and try again.

The error 'Failed to read values in CFPrefsPlistSource' occurs when trying to access user defaults in an iOS app or Today Extension that uses Xcode 8 beta 2. This issue affects developers who are sharing data between their apps and Today Extensions.

This warning can be frustrating because it prevents the app from reading user preferences, which can lead to unexpected behavior or crashes. However, by following the steps outlined in this guide, you should be able to resolve the issue and access your user defaults successfully.

⚠️ Common Causes

  • The primary reason for this error is that Xcode 8 beta 2 introduces a new feature that restricts the use of `kCFPreferencesAnyUser` with a container. This is done to improve security and prevent unauthorized access to user data.
  • Another possible cause could be that the app or Today Extension is not properly configured to handle the new feature, leading to the error.

✅ Best Solutions to Fix It

Using kCFPreferencesGroupedWithContainer

  1. Step 1: To fix this issue, update your code to use `kCFPreferencesGroupedWithContainer` instead of `kCFPreferencesAnyUser`. This will allow you to access user defaults while still following the security guidelines.
  2. Step 2: Replace all occurrences of `kCFPreferencesAnyUser` with `kCFPreferencesGroupedWithContainer` in your app's or Today Extension's code.
  3. Step 3: Additionally, ensure that your app's and Today Extension's Info.plist files are correctly configured to use the new feature.

Configuring cfprefsd

  1. Step 1: Another approach is to configure cfprefsd to allow access to user defaults for your app or Today Extension. This can be done by adding the following key-value pairs to your app's or Today Extension's Info.plist file:
  2. Step 2: Add a new key `CFPreferencesGroupedWithContainer` with value `YES`.
  3. Step 3: Also, ensure that the `CFPreferencesAnyUser` key is removed from your app's or Today Extension's code.

✨ Wrapping Up

By following one of these methods, you should be able to resolve the 'Failed to read values in CFPrefsPlistSource' error and access your user defaults successfully. Remember to test your app or Today Extension thoroughly after making any changes to ensure that they are working as expected.

Did this fix your problem?

If not, try searching for specific error codes.

🔍 Search Error Database

❓ Frequently Asked Questions