<!--
{
  "availability" : [
    "iOS: 13.0.0 -",
    "iPadOS: 13.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "ARKit",
  "identifier" : "/documentation/ARKit/ARReferenceImage/validate(completionHandler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "ARKit"
    ],
    "preciseIdentifier" : "c:objc(cs)ARReferenceImage(im)validateWithCompletionHandler:"
  },
  "title" : "validate(completionHandler:)"
}
-->

# validate(completionHandler:)

Determines whether the reference image is valid.

```
func validate(completionHandler: @escaping @Sendable ((any Error)?) -> Void)
```

## Discussion

ARKit considers certain images invalid for image tracking (for example, an image that’s all white). Call this function on a reference image you create programmatically to make sure ARKit can track it, before passing it in to your session’s [`detectionImages`](/documentation/ARKit/ARWorldTrackingConfiguration/detectionImages) array.

You only need this function when you create a reference image programmatically, because Xcode performs this validation for you when you create a reference image in an asset catalog.

---

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)