Upgrade from 5.x to 6.0.0
Version 6.0.0 of the Customer.io Flutter SDK gets our native iOS SDK from its Swift package, including when your app builds with CocoaPods. Most apps don't need to change anything, but a few iOS setups need a Podfile or Xcode change.
What changed?
CocoaPods’ central repository (trunk) stopped accepting new versions on December 2, 2026, so version 5.3.2 is the last version of the Customer.io iOS SDK that Customer.io publishes as CocoaPods pods. Newer versions are only available as a Swift package on GitHub.
From version 6.0.0, the Flutter SDK gets the iOS SDK from that Swift package in both of Flutter’s iOS install paths:
- Swift Package Manager, which is on by default in the Flutter versions that the SDK supports: Flutter builds the plugin from its Swift package, which gets the iOS SDK from GitHub. Nothing changes for you.
- CocoaPods (Swift Package Manager turned off, or an add-to-app host app): You keep the plugin’s
customer_ioandcustomer_io_richpushpods and their subspecs, but they don’t install any Customer.io pods anymore. Xcode downloads the iOS SDK from GitHub when it builds your app.
The plugin always uses the iOS SDK version set as native_sdk_version in its pubspec.yaml, so you don’t pick it yourself.
Your Dart code, your AppDelegate, and your Android project don’t change.
Find your setup
Most apps don’t need to change anything. Find your setup in the table below.
| Your setup | What to do |
|---|---|
Swift Package Manager is on, and ios/Podfile has no customer_io lines | Nothing. |
CocoaPods, with pod 'customer_io/. lines in your app target | Nothing. When you run pod install, CocoaPods removes the old Customer.io pods from your Podfile.. |
A Notification Service Extension with pod 'customer_io_richpush/fcm' | Keep the pod line, and make sure NotificationService. has import UserNotifications. See Notification Service Extension. |
Swift Package Manager is on, but ios/Podfile still has pod 'customer_io/. lines | Remove those lines. See Swift Package Manager with leftover pod lines. |
An add-to-app module that you build with flutter build ios-framework or flutter build swift-package | Embed the module with CocoaPods instead. See Add-to-app modules. |
A Live Activity widget with pod 'CustomerIOLiveActivitiesTemplates' and pod 'CustomerIOLiveActivitiesAttributes' | Replace the pods with the Swift package, including when Swift Package Manager is on. See Live Activity widget. |
pod 'CioFirebaseWrapper/Core', with Firebase from somewhere other than CocoaPods, like Swift Package Manager | Replace it with the new customer_io/fcm-core subspec. See FCM with Firebase from outside CocoaPods. |
Any other pod 'CustomerIO/. or pod 'CioFirebaseWrapper' line that you added yourself | Remove it. The customer_io pod includes the iOS SDK. Use its fcm, location, geofence, and liveactivities subspecs for those modules. |
The customerio-ios Swift package in your Xcode project with an exact version, usually for a widget | Change it to Up to Next Major Version from 5.. See Exact versions in your Xcode project. |
When your Podfile installs one of the plugin’s pods (customer_io or customer_io_richpush), pod install stops with a message that names the lines to change. With Swift Package Manager on, leftover subspec lines only get a warning. If your app uses Swift Package Manager and its Podfile has neither of the plugin’s pods, for example only the widget pods, you don’t get a message, so check the table yourself.
Upgrade process
-
Update the SDK version in your
pubspec.yaml, and then runflutter pub get:YAMLdependencies: customer_io: ^6.0.2 -
Make the changes from Find your setup that apply to your app.
-
If you use CocoaPods, run
pod installfrom youriosfolder, or letflutter build iosrun it for you. You don’t needpod updateorpod repo updatefor Customer.io. -
Build your app. If you commit
ios/Runner.xcworkspace/xcshareddata/swiftpm/Package.resolved, commit the version that this build writes. See Xcode and network access.
If you archive release builds with one signing identity for every target, like fastlane’s codesigning_identity, change that before your first release archive. See Release archive fails to sign Customer.io_ targets.
Xcode and network access
The Customer.io iOS SDK’s Swift package needs Xcode 16 or later, because one of the packages it depends on requires Swift 6 tools. Your framework might need a later version. For example, React Native 0.81 and later need Xcode 16.1 or later. If you send push notifications through FCM, you should also check Firebase’s iOS release notes for the Xcode version that your Firebase release needs.
Xcode downloads the SDK and the packages it depends on from GitHub when it resolves packages. If your build machines or CI can’t reach github.com, allow access to these repositories or mirror them:
https://github.com/customerio/customerio-ioshttps://github.com/customerio/cdp-analytics-swifthttps://github.com/customerio/jisthttps://github.com/LaunchDarkly/swift-eventsourcehttps://github.com/segmentio/sovran-swifthttps://github.com/segmentio/jsonsafeencoding-swift
If you commit Package.resolved, update it after each SDK update. Resolve packages once for the workspace or project that your CI builds, without -onlyUsePackageVersionsFromResolvedFile or -disableAutomaticPackageResolution, and commit the updated file. CI builds that use those options need the updated file to find the new SDK version.
xcodebuild -resolvePackageDependencies -workspace ios/YourApp.xcworkspace -scheme YourAppSwift Package Manager with leftover pod lines
With Swift Package Manager on, Flutter builds the plugin from its Swift package, so subspec lines that you added for CocoaPods don’t change the plugin, and pod install warns about them. A customer_io/fcm line still installs FirebaseMessaging from CocoaPods, as in 5.x, which gives your app a second copy of Firebase next to the one from FlutterFire’s Swift package.
If your Podfile also has a pod 'customer_io' line without a subspec, the plugin would be built twice, so pod install stops with this message:
Swift Package Manager is on for this app, so Flutter already builds the customer_io plugin from its Swift package.To fix the warning or the error:
-
Remove the
pod 'customer_io/...'lines from your app target inios/Podfile. If your Notification Service Extension target haspod 'customer_io_richpush/fcm', keep it. -
For each subspec you used, add its key to
android/gradle.properties. With Swift Package Manager on, these keys turn on the iOS modules as well as the Android ones.Subspec android/gradle.properties locationcustomerio_location_enabled=truegeofencecustomerio_geofence_enabled=trueliveactivitiescustomerio_live_activities_enabled=trueWith Swift Package Manager on, the plugin’s Swift package reads the
customerio_..._enabledkeys fromandroid/gradle.propertieswhen Xcode loads the package. Use version 6.0.2 or later of the plugin, which finds that file wherever your build starts. Earlier versions can miss the file, and then Xcode builds your app without these modules and doesn’t show an error.Swift Package Manager caches what the plugin’s package reads, and doesn’t notice when you change one of these keys. After you change a key, delete the cache before you build again. It isn’t enough to run the
flutter cleancommand or delete Xcode’s DerivedData folder.BASHrm -rf ~/Library/Caches/org.swift.swiftpm/manifests -
If you used
customer_io/fcm, it might have been where your app got FirebaseMessaging. With Swift Package Manager on, your app gets it from FlutterFire, so make sure yourpubspec.yamlhas versions that support Swift Package Manager:firebase_core: ^3.5.0andfirebase_messaging: ^15.2.0or later.
To keep building with CocoaPods instead, turn Swift Package Manager off for your app in pubspec.yaml, and then run flutter pub get. This setting applies on every machine that builds your app, including CI. The flutter config --no-enable-swift-package-manager command only changes the machine you run it on.
flutter:
config:
enable-swift-package-manager: falseFCM with Firebase from outside CocoaPods
If your app builds with CocoaPods but gets Firebase another way, like Swift Package Manager, replace pod 'CioFirebaseWrapper/Core' with the new customer_io/fcm-core subspec. It installs Customer.io’s FCM support without the FirebaseMessaging pod.
pod 'customer_io/fcm-core', :path => '.symlinks/plugins/customer_io/ios'In an add-to-app host app, use the path into your Flutter module instead, like ../my_flutter/.ios/.symlinks/plugins/customer_io/ios. The pod install message shows the path for your app.
Don’t use customer_io/fcm in this setup, because it installs FirebaseMessaging from CocoaPods, which gives your app a second copy of Firebase. If your app gets Firebase from CocoaPods, keep using customer_io/fcm.
Notification Service Extension
Your Notification Service Extension now gets the push module from the iOS SDK’s Swift package, whether your app uses Swift Package Manager or CocoaPods. The old pod made the UserNotifications types available to your extension’s code, and the Swift package doesn’t, so make sure NotificationService.swift has its own import. Without it, the build fails with Cannot find type 'UNNotificationServiceExtension' in scope.
import CioMessagingPushFCM
import UserNotificationsHow your extension gets the push module depends on how your app installs the plugin:
- CocoaPods: Keep
pod 'customer_io_richpush/fcm'in your extension’s target block inios/Podfile. - Swift Package Manager: Add the MessagingPushFCM product of the
customerio-iospackage to your extension, as in the Swift Package Manager steps in push setup. Xcode resolves it to the iOS SDK version that the plugin sets. If your extension already usescustomer_io_richpushwith Swift Package Manager on, you can keep it. If it linksFlutterGeneratedPluginSwiftPackage, as the 4.0.0 upgrade guide described, you can replace that with MessagingPushFCM, which leaves Flutter and Firebase out of your extension.
Live Activity widget
The CustomerIOLiveActivitiesTemplates and CustomerIOLiveActivitiesAttributes pods stop at version 5.3.2. If your widget keeps them while your app moves to newer versions of the iOS SDK, a later change to the Live Activity types could break your live notifications without a build error.
When your Podfile also installs one of the plugin’s pods, pod install stops and lists these steps. If your app uses Swift Package Manager and the widget pods are the only Customer.io pods in your Podfile, you don’t get a message, so make the change yourself:
- In
ios/Podfile, removepod 'CustomerIOLiveActivitiesTemplates'andpod 'CustomerIOLiveActivitiesAttributes'. If nothing else is left in thetargetblock for your widget, remove the block too. - Open
ios/Runner.xcworkspacein Xcode, select your project, and go to the Package Dependencies tab. - Click + and enter
https://github.com/customerio/customerio-ios.git. Set the dependency rule to Up to Next Major Version from5.0.0, and click Add Package. - Add the LiveActivities_Attributes and LiveActivities_Templates products to your widget target.
- From your
iosfolder, runpod install, so CocoaPods removes its setup from the widget target. If none of your targets need CocoaPods anymore, you can remove CocoaPods integration from your project.
You don’t need to change the Swift code in your widget.
Add-to-app modules
From version 6.0.0 of the plugin, building your Flutter module with flutter build ios-framework or flutter build swift-package fails with Packages are not supported when using legacy build locations, because Xcode doesn’t allow Swift packages in the way these commands build your module’s plugins.
Embed your Flutter module in your host app with CocoaPods instead, by calling install_all_flutter_pods in your host app’s Podfile. Flutter’s current add-to-app guide uses Swift Package Manager, so follow the Use CocoaPods and the Flutter SDK method in Flutter’s earlier add-to-app setup guide. The plugin then installs the same way it does in any CocoaPods app.
-
Remove what your earlier setup added to your host app, because CocoaPods now adds Flutter and its plugins for you:
- From
flutter build ios-framework:App.xcframework,Flutter.xcframework,FlutterPluginRegistrant.xcframework, and your plugins’ frameworks under your app target’s General > Frameworks, Libraries, and Embedded Content, and anypod 'Flutter', :podspec => ...line in your Podfile. - From
flutter build swift-package: theFlutterNativeIntegrationpackage and its entry under Frameworks, Libraries, and Embedded Content, theflutter_integration.shpre-action in your scheme and run script phase in your target, and theFLUTTER_SWIFT_PACKAGE_OUTPUTbuild setting.
- From
-
Set
platform :ios, '15.0'or higher at the top of your host app’s Podfile, and set your host app target’s iOS deployment target to 15.0 or later. The plugin’s pod needs iOS 15.0, and with a lower Podfile platform,pod installstops before yourpost_installblock runs. -
If your host app’s build fails on a deployment target, raise the pod targets to 15.0 with the plugin’s Podfile helper. Xcode 27 rejects targets below iOS 15.0, and some pods in your host app’s install, like the Flutter pod, declare a lower one. Load the helper from your Flutter module, and call it at the end of your host app’s
post_installblock. It also raises your host app’s targets and extension targets to 15.0 if they’re lower.RUBYplatform :ios, '15.0' flutter_application_path = '../my_flutter' load File.join(flutter_application_path, '.ios', 'Flutter', 'podhelper.rb') target 'MyApp' do install_all_flutter_pods(flutter_application_path) end require File.expand_path( File.join(flutter_application_path, '.ios', '.symlinks', 'plugins', 'customer_io', 'ios', 'cocoapods_deployment_target'), __dir__ ) post_install do |installer| flutter_post_install(installer) if defined?(flutter_post_install) CustomerIO::CocoaPodsDeploymentTarget.normalize!( installer, minimum_ios_version: '15.0' ) end -
Run
pod installfrom your host app’s folder.
Exact versions in your Xcode project
If your Xcode project adds the customerio-ios package itself, usually for a widget, with the Exact Version rule, Xcode can’t resolve packages whenever a plugin release moves to a new iOS SDK version. You see an error like this, where one version is the plugin’s native_sdk_version and the other is yours:
Dependencies could not be resolved because root depends on 'customerio-ios' <version> and root depends on 'customerio-ios' <other version>.In your project’s Package Dependencies tab, change the rule for customerio-ios to Up to Next Major Version from 5.0.0. Xcode then resolves the version that the plugin uses.
Troubleshooting
pod install from outside your ios folder stops
With Swift Package Manager on, if you run pod install from outside your ios folder, for example with --project-directory=ios, Flutter’s pod helper adds the customer_io pod itself. pod install then stops with the Swift Package Manager is on for this app message, even if your Podfile has no customer_io line. Run cd ios && pod install instead, or let flutter build ios run it.
Building Pods.xcodeproj fails with Packages are not supported when using legacy build locations
With CocoaPods, the customer_io pod now includes a Swift package. CocoaPods’ Pods.xcodeproj uses legacy build locations, so Xcode can’t build that package when you build Pods.xcodeproj by itself, as some scripts and pod caching tools do. Build ios/Runner.xcworkspace instead.
Your Podfile skips Pods project generation
If your Podfile sets install! 'cocoapods', :skip_pods_project_generation => true, CocoaPods doesn’t generate a Pods project, so the plugin can’t add the iOS SDK to its pods. Whatever generates your Xcode projects needs to add the Swift package https://github.com/customerio/customerio-ios.git, at the plugin’s native_sdk_version, to the targets that build the customer_io and customer_io_richpush pods.
Xcode can’t resolve packages because of LaunchDarkly
If your app also uses LaunchDarkly’s iOS SDK and Xcode can’t resolve packages, see 'customerio-ios' is incompatible with 'ios-client-sdk'.
Release archive fails to sign Customer.io_ targets
If archiving a release build fails with Signing for "Customer.io_CioMessagingPushFCM" requires a development team, or the same error for another Customer.io_ target, your build command passes one signing identity to every target. See Release archive fails to sign Customer.io_ targets.