<!--
{
  "availability" : [
    "iOS: 3.0.0 -",
    "iPadOS: 3.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.4.0 -",
    "tvOS: 9.0.0 -",
    "visionOS: 1.0.0 -",
    "watchOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Foundation",
  "identifier" : "/documentation/Foundation/NSPredicate/predicateFormat",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "Foundation"
    ],
    "preciseIdentifier" : "c:objc(cs)NSPredicate(py)predicateFormat"
  },
  "title" : "predicateFormat"
}
-->

# predicateFormat

The predicate’s format string.

```
var predicateFormat: String { get }
```

## Discussion

The return value of this property is not guaranteed to be the same as the string used to create the predicate using [`predicateWithFormat:`](/documentation/Foundation/NSPredicate/predicateWithFormat:) or similar methods.

You cannot use this method to create a persistent representation of a predicate suitable for recreating the original predicate. If you need a persistent representation of a predicate, create an archive instead, as described in [Object archiving](https://developer.apple.com/library/archive/documentation/General/Conceptual/DevPedia-CocoaCore/Archiving.html#//apple_ref/doc/uid/TP40008195-CH1) ([`NSPredicate`](/documentation/Foundation/NSPredicate) adopts the [`NSCoding`](/documentation/Foundation/NSCoding) protocol).

---

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)