<!--
{
  "availability" : [
    "iOS: 14.5.0 -",
    "iPadOS: 14.5.0 -",
    "macCatalyst: 14.5.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "StoreKit",
  "identifier" : "/documentation/StoreKit/SKAdNetwork/endImpression(_:completionHandler:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "StoreKit"
    ],
    "preciseIdentifier" : "c:objc(cs)SKAdNetwork(cm)endImpression:completionHandler:"
  },
  "title" : "endImpression(_:completionHandler:)"
}
-->

# endImpression(_:completionHandler:)

Indicates that your app is no longer presenting a view-through ad to the user.

```
class func endImpression(_ impression: SKAdImpression, completionHandler completion: (@Sendable ((any Error)?) -> Void)? = nil)
```

## Parameters

`impression`

An instance of [`SKAdImpression`](/documentation/StoreKit/SKAdImpression) with the properties set for the view-through ad that you presented. This must be the same instance you provide in [`startImpression(_:completionHandler:)`](/documentation/StoreKit/SKAdNetwork/startImpression(_:completionHandler:)).

`completion`

The callback handler you provide to handle any tasks relevant to concluding the ad impression.

## Discussion

Call this method when you end the presentation of a view-through ad and it’s no longer visible to the user. To help ensure it’s a valid impression, StoreKit only records the impression if the ad displays for a minimum amount of time. That minimum is 2 seconds on devices running iOS 15.4 and iPadOS 15.4 and later, and 3 seconds on devices running earlier versions of iOS and iPadOS. If the app displays the ad for fewer than the minimum number of seconds, StoreKit doesn’t record the ad impression for attribution.

> Note:
> To ensure that SKAdNetwork records the impression, call ``doc://com.apple.storekit/documentation/StoreKit/SKAdNetwork/endImpression(_:completionHandler:)`` after the impression ends, regardless of whether ``doc://com.apple.storekit/documentation/StoreKit/SKAdNetwork/startImpression(_:completionHandler:)`` returns an error in the completion handler.

StoreKit records a maximum of 15 view-through ad impressions per source app for various products before discarding the oldest-recorded impression.

For more information about ad impressions and attributions, see [Receiving ad attributions and postbacks](/documentation/StoreKit/receiving-ad-attributions-and-postbacks).

---

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)