The simplest way to add premium features to your Swift app
Transform any SwiftUI view into a premium feature with just one line of code. InAppKit handles StoreKit complexity so you can focus on building great features.
ContentView()
.withPurchases("com.yourapp.pro")
🚀 Ready-to-use Paywalls Beautiful, localized paywalls that work out of the box |
💳 Smart Purchase Options Flexible pricing cards with marketing badges and savings indicators |
- 🚀 One-line setup - Add premium features instantly
- 🎯 Type-safe features - Enum-based feature gating prevents errors
- 💳 StoreKit integration - Handles purchases, receipts, and validation
- 🎨 Customizable paywalls - Beautiful UI out of the box, fully customizable
- 🌍 Localization support - Built-in internationalization with fallback safety
- 📱 iOS 17+ support - Built with latest SwiftUI and StoreKit 2
- iOS 17.0+
- Xcode 15.0+
- Swift 5.9+
dependencies: [
.package(url: "https://github.com/tddworks/InAppKit.git", from: "1.0.0")
]
import InAppKit
ContentView()
.withPurchases("com.yourapp.pro")
Text("Premium Content")
.requiresPurchase() // Shows paywall if not purchased
InAppKit automatically:
- Creates and displays paywalls when needed
- Handles StoreKit purchases
- Validates receipts
- Remembers purchase state
Learn core concepts: Products, Features, and Paywalls
Choose the right strategy: Freemium, Premium, or Subscription
Customize UI, add marketing info, and advanced configuration
Multi-language support with 30+ localization keys and fallback safety
Complete API documentation and advanced features
enum AppFeature: String, AppFeature {
case removeAds = "remove_ads"
case cloudSync = "cloud_sync"
case exportPDF = "export_pdf"
}
ContentView()
.withPurchases(products: [
Product("com.yourapp.pro", features: AppFeature.allCases)
])
.withPaywall { context in
PaywallView(products: context.availableProducts)
}
- Issues: GitHub Issues
- Discussions: GitHub Discussions
- Documentation: docs/
We welcome contributions! Please see our Contributing Guide for details.
Apache-2.0 License. See LICENSE for details.
- Built on Apple's StoreKit 2
- Inspired by SwiftUI's declarative approach
- Designed for modern iOS development
Ready to add premium features? → Start with the Getting Started Guide
InAppKit - Because in-app purchases shouldn't be complicated. 🚀
Made with ❤️ by the TDDWorks team