---
title: allowsCloudEncryption
framework: coredata
role: symbol
role_heading: Instance Property
path: coredata/nsattributedescription/allowscloudencryption
---

# allowsCloudEncryption

A Boolean value that determines whether to encrypt the attribute’s value.

## Declaration

```swift
var allowsCloudEncryption: Bool { get set }
```

## Mentioned in

Configuring Attributes

## Discussion

Discussion Set this property to true to store the attribute’s value in an encrypted form in iCloud. Only use this property with new attributes. Core Data doesn’t support encrypting attributes that already exist in your CloudKit schema, or attributes that represent relationships between entities. You can also set this property using the Allow Cloud Encryption attribute in the Attributes inspector of the Core Data model editor. important: Attributes can’t change their encryption state after you promote them to your production CloudKit schema. If you choose to encrypt an attribute, it always remains that way.

## See Also

### Configuring the behavior

- [allowsExternalBinaryDataStorage](coredata/nsattributedescription/allowsexternalbinarydatastorage.md)
- [defaultValue](coredata/nsattributedescription/defaultvalue.md)
- [preservesValueInHistoryOnDeletion](coredata/nsattributedescription/preservesvalueinhistoryondeletion.md)
- [valueTransformerName](coredata/nsattributedescription/valuetransformername.md)
