<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: -"
  ],
  "documentType" : "symbol",
  "framework" : "ManagedSettings",
  "identifier" : "/documentation/ManagedSettings/SafariSettings/cookiePolicy-swift.property",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Managed Settings"
    ],
    "preciseIdentifier" : "s:15ManagedSettings06SafariB0V12cookiePolicyAC06CookieE0OSgvp"
  },
  "title" : "cookiePolicy"
}
-->

# cookiePolicy

Defines the conditions under which Safari accepts cookies.

```
var cookiePolicy: SafariSettings.CookiePolicy? { get set }
```

## Discussion

The value is `nil` if this setting has not been applied.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)