iOS configuration options
This section provides step-by-step instructions for configuring your iOS application to enable messaging services using Pushwoosh. Choose between certificate-based or token-based configuration depending on your project requirements.
iOS certificate-based configuration
Anchor link toLearn how to configure Pushwoosh for iOS using certificate-based authentication for APNs (Apple Push Notification Service).
iOS token-based configuration
Anchor link toSet up Pushwoosh with token-based authentication for APNs, offering a more secure and efficient alternative to certificates.
Choosing between .p12 certificates and .p8 keys for iOS push notifications
Anchor link toWhen configuring iOS push notifications in Pushwoosh, you must authenticate with Apple Push Notification service (APNs). There are two supported methods:
.p12certificate: the traditional, certificate-based approach..p8key: the modern, token-based method recommended by Apple.
This guide will help you determine which method best fits your use case.
Understanding the options
Anchor link to| Feature | .p12 Certificate | .p8 Authentication Key |
|---|---|---|
| How it works | Uses a cryptographic certificate to establish trust. | Uses a persistent token signed by a private key. |
| File | .p12 file containing the certificate and private key. | .p8 file containing a private key. |
| Expiration | Expires (typically yearly); requires renewal. | Does not expire automatically. |
| Setup | More complex to generate and manage. | Generally simpler to set up. |
| Usage | One certificate per Bundle ID for each environment. | One key supports multiple apps and both environments. |
| Recommendation | Legacy method. Use only for existing setups. | Recommended by Apple and Pushwoosh. |
Pros and cons of each method
Anchor link to.p12 certificate: the traditional approach
Anchor link toPros:
- Widely supported.
- Allows separate certificates for development and production.
Cons:
- Certificates expire and require renewal. Failure to renew can disrupt push delivery.
- More complex to manage.
.p8 key: the modern, recommended approach
Anchor link toPros:
- No renewals required, reducing maintenance overhead.
- Easier to generate and integrate.
- One key works across projects.
- Recommended by Apple and Pushwoosh.
Cons:
- If compromised, all associated apps are at risk. Secure your
.p8key properly.
Which method should you choose?
Anchor link toWe recommend using the .p8 key method for all new projects. It is simpler, more scalable, and aligned with Apple’s best practices.
Use .p12 certificates only if:
- You have existing infrastructure dependent on
.p12certificates. - You require strict environment separation that cannot be achieved with a
.p8key.