<!--
{
  "availability" : [
    "macCatalyst: 13.0.0 -",
    "macOS: 10.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Security",
  "identifier" : "/documentation/Security/SecKeychainSettings/lockInterval",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Security"
    ],
    "preciseIdentifier" : "c:@S@SecKeychainSettings@FI@lockInterval"
  },
  "title" : "lockInterval"
}
-->

# lockInterval

The number of seconds to wait before the keychain locks.

```
var lockInterval: UInt32
```

## Discussion

If you set [`useLockInterval`](/documentation/Security/SecKeychainSettings/useLockInterval) to <doc://com.apple.documentation/documentation/Swift/false>, set [`lockInterval`](/documentation/Security/SecKeychainSettings/lockInterval) to `INT_MAX` to indicate that the keychain never locks.

---

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)