<!--
{
  "availability" : [
    "iOS: 16.0.0 - 27.0.0",
    "iPadOS: 16.0.0 - 27.0.0",
    "macCatalyst: 16.0.0 - 27.0.0",
    "visionOS: 1.0.0 - 27.0.0"
  ],
  "documentType" : "symbol",
  "framework" : "StoreKit",
  "identifier" : "/documentation/StoreKit/AppStore/presentOfferCodeRedeemSheet(in:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "StoreKit"
    ],
    "preciseIdentifier" : "s:8StoreKit03AppA0O27presentOfferCodeRedeemSheet2inySo13UIWindowSceneC_tYaKFZ"
  },
  "title" : "presentOfferCodeRedeemSheet(in:)"
}
-->

# presentOfferCodeRedeemSheet(in:)

Displays a sheet in the window scene that enables customers to redeem an offer code that you configure in App Store Connect.

```
@MainActor static func presentOfferCodeRedeemSheet(in scene: UIWindowScene) async throws
```

## Parameters

`scene`

The <doc://com.apple.documentation/documentation/UIKit/UIWindowScene> that StoreKit uses to display the offer code redemption sheet.

## Discussion

## Discussion

The [`presentOfferCodeRedeemSheet(in:)`](/documentation/StoreKit/AppStore/presentOfferCodeRedeemSheet(in:)) method displays a system sheet in the window scene, where customers can enter and redeem offer codes. If you generate offer codes in App Store Connect, call this function to enable customers to redeem the offer. To display the sheet using SwiftUI, see <doc://com.apple.documentation/documentation/SwiftUI/View/offerCodeRedemption(isPresented:onCompletion:)>.

> Important:
> Set up offer codes in App Store Connect before calling this API. Customers can only redeem these offers in your app through the redemption sheet; don’t use a custom UI.

For more information on offer codes, see [Supporting offer codes in your app](/documentation/StoreKit/supporting-offer-codes-in-your-app).

When customers redeem an offer code, StoreKit emits the resulting transaction in [`updates`](/documentation/StoreKit/Transaction/updates). Set up a transaction listener as soon as your app launches to receive new transactions while the app is running. For more information, see [`updates`](/documentation/StoreKit/Transaction/updates).

In Mac apps built with Mac Catalyst, this method throws a [`StoreKitError.unknown`](/documentation/StoreKit/StoreKitError/unknown) error.

---

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)