<!--
{
  "availability" : [
    "macOS: 10.9.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "XPC",
  "identifier" : "/documentation/XPC/XPC_ACTIVITY_INTERVAL",
  "metadataVersion" : "0.1.0",
  "role" : "Global Variable",
  "symbol" : {
    "kind" : "Global Variable",
    "modules" : [
      "XPC"
    ],
    "preciseIdentifier" : "c:@XPC_ACTIVITY_INTERVAL"
  },
  "title" : "XPC_ACTIVITY_INTERVAL"
}
-->

# XPC_ACTIVITY_INTERVAL

An integer property that indicates the desired time interval of the activity in seconds.

```
let XPC_ACTIVITY_INTERVAL: UnsafePointer<CChar>
```

## Discussion

The activity doesn’t run more than once per time interval. Due to the nature of XPC Activity finding an opportune time to run the activity, any two occurrences may be more or less than [`XPC_ACTIVITY_INTERVAL`](/documentation/XPC/XPC_ACTIVITY_INTERVAL) seconds apart, but on average are [`XPC_ACTIVITY_INTERVAL`](/documentation/XPC/XPC_ACTIVITY_INTERVAL) seconds apart. The presence of this key implies the following, unless you override these values:

- [`XPC_ACTIVITY_REPEATING`](/documentation/XPC/XPC_ACTIVITY_REPEATING) with a value of `true`
- [`XPC_ACTIVITY_DELAY`](/documentation/XPC/XPC_ACTIVITY_DELAY) with a value of half the interval. The delay enforces a minimum distance between any two occurrences.
- [`XPC_ACTIVITY_GRACE_PERIOD`](/documentation/XPC/XPC_ACTIVITY_GRACE_PERIOD) with a value of half the interval. The grace period is the amount of time that passes after the end of the interval before more aggressive scheduling occurs. The grace period doesn’t increase the size of the interval.

---

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)