> For the complete documentation index, see [llms.txt](https://docs.appmysite.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.appmysite.com/app/monetization/configure-in-app-purchases-ios.md).

# Configure In-app Purchases (iOS)

### How to connect in-app purchases with App Store Connect

If your app unlocks virtual goods, features, subscriptions, or premium content, Apple requires you to use In-App Purchases (IAP).

Follow the steps below to connect your in-app purchases with App Store Connect.

#### Step 1: Accept the Paid Apps Agreement

* Log in to [App Store Connect](https://appstoreconnect.apple.com/).
* Navigate to the Business section.
* Accept the Paid Apps Agreement.

{% hint style="warning" %}
You cannot enable in-app purchases unless the Paid Apps Agreement is accepted.
{% endhint %}

#### Step 2: Configure in-app purchases in App Store Connect

* In your App Store Connect account, navigate to Apps from the top menu.
* Select your app.
* From the side menu, locate In-App Purchases under Monetization.
* Click Create and select the appropriate in-app purchase type.
* Enter the Product ID generated in your AppMySite in-app purchase dashboard.
* Add a clear product name and description.
* Configure price, localization, and availability.

{% hint style="danger" %}
The Product ID entered in App Store Connect must exactly match the Product ID generated in your AppMySite dashboard.
{% endhint %}

#### For subscriptions (Auto-renewing or Non-renewing)

* Go to App Store Connect > Apps > Select your app.
* &#x20;Under Monetization, click Subscriptions.
* Click Create to create a subscription group (optional but recommended).
* Assign a clear name to the group.
* Click Create under Subscriptions.
* Enter the Product ID generated in your AppMySite in-app purchase dashboard.
* Add a descriptive name for users.
* Configure pricing, localization, and availability.

#### Step 3: Configure App Store Server Notifications

To connect Apple’s servers with your app backend, you must configure server notifications.

* In your App Store Connect account, navigate to Apps and select your app.
* In the sidebar under General, click App Information.
* Scroll to App Store Server Notifications.
* In both the Production Server URL section as well as the Sandbox Server URL section, click Set Up URL.
* Paste the URL obtained from the "Server URL" field from the In-app Purchase configuration screen on AppMySite in both the sections.&#x20;
* Click Save to complete.

{% hint style="warning" %}
Both Production and Sandbox Server URLs must be configured to ensure proper in-app purchase validation.
{% endhint %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.appmysite.com/app/monetization/configure-in-app-purchases-ios.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
