---
title: cachePolicy
framework: foundation
role: symbol
role_heading: Instance Property
path: foundation/urlrequest/cachepolicy-swift.property
---

# cachePolicy

The request’s cache policy.

## Declaration

```swift
var cachePolicy: URLRequest.CachePolicy { get set }
```

## See Also

### Working with a cache policy

- [URLRequest.CachePolicy](foundation/urlrequest/cachepolicy-swift.typealias.md)
- [NSURLRequest.CachePolicy](foundation/nsurlrequest/cachepolicy-swift.enum.md)
