appmigrationkit
Transfer app data to or from other platforms using AppMigrationKit
Install / Use
npx skills add dpearson2699/swift-ios-skills --skill appmigrationkitInstalls into whichever agent you are using.
SKILL.md
Installable skill definition
Quality Score
Category
Development & EngineeringSupported Platforms
Our assessment of appmigrationkit
appmigrationkit scores 86/100 on our quality scale, 2426th of 4,698 Development & Engineering skills we index.
Its SKILL.md is 18 KB long, well organised into 27 sections with 15 code examples: a thorough specification that gives an agent plenty to work with.
With 1,143 GitHub stars, it is one of the more widely adopted skills in the catalogue.
Maintenance, license and trust
- The repository was last updated about 4 months ago. That is recent enough to be usable, but agent tooling moves fast, so check the instructions against your agent's current version.
- Our last check on 2026-11-03 found the source still online.
- No license is declared. By default that means all rights are reserved: you can read it, but reusing or redistributing it is not clearly permitted. Ask the author before building on it commercially.
- Its trust signals score 86/100, with 1 caution from licensing, adoption, age or documentation. These come from repository metadata, not a code audit — read the skill file before letting an agent act on it.
Safety scan
No issues foundOur scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful.
AI review by kimi-k2.7-code on 2026-10-06. Automated pattern scan on 2026-10-05. It catches known dangerous patterns, not every risk — read a skill before letting an agent act on it.
appmigrationkit compared with similar skills
All 4 of these similar skills score higher than appmigrationkit; compare them before choosing.
| Skill | Score | Stars | Updated | Format |
|---|---|---|---|---|
| appmigrationkit (this skill)by dpearson2699 | 86 | 1.1k | 4mo ago | SKILL.md |
| taste-skillby Leonxlnx | 100 | 116.8k | 8d ago | CLAUDE.md |
| ai-job-searchby ai-job-search-dev | 100 | 72.1k | today | CLAUDE.md |
| claude-howtoby luongnv89 | 100 | 47.3k | 2d ago | CLAUDE.md |
| lobehubby lobehub | 100 | 85.6k | today | MCP Server |
Frequently asked questions
- How do I install appmigrationkit?
- Run
npx skills add dpearson2699/swift-ios-skills --skill appmigrationkit. The install tabs above show the steps for each supported agent. - Which AI agents does appmigrationkit work with?
- It is written for Universal, as a SKILL.md file. Other agents that read the same format can often use it too.
- Is appmigrationkit safe to use?
- Our scan of the whole file found no instruction hijacking, hidden characters, credential access, data exfiltration or destructive commands. An AI review of the same text found nothing harmful. It declares no license and scores 86/100 on trust signals. Skills are instructions an agent will follow, so read the file before installing it and do not approve commands you do not understand.
- Is appmigrationkit still maintained?
- The repository was last updated about 4 months ago. That is recent enough to be usable, but agent tooling moves fast, so check the instructions against your agent's current version.
Skill content
View source on GitHubname: appmigrationkit description: "Transfer app data to or from other platforms using AppMigrationKit. Use when implementing system-orchestrated one-time migration between iOS and Android or another platform, building an AppMigrationExtension, packaging transportable resources with ResourcesArchiver, importing resources on the destination device, reporting import progress, handling migration errors and app group cleanup, checking MigrationStatus, or testing migration code with AppMigrationTester."
AppMigrationKit
One-time cross-platform data transfer for app resources. Enables apps to export data to or import data from another platform (for example, Android) during device setup or onboarding. AppMigrationKit APIs are iOS 26.0+ / iPadOS 26.0+; the data-container entitlement is iOS 26.1+ / iPadOS 26.1+ / Mac Catalyst 26.1+. Swift 6.3.
Beta-sensitive. AppMigrationKit is new in iOS 26 and may change before GM. Re-check current Apple documentation before relying on specific API details.
AppMigrationKit uses an app extension model. The system orchestrates the transfer between devices. The app provides an extension conforming to export and import protocols, and the system calls that extension at the appropriate time. The app itself never manages the network connection between devices.
Contents
- Architecture Overview
- Setup and Entitlements
- App Migration Extension
- Exporting Resources
- Importing Resources
- Migration Status
- Progress Tracking
- Testing
- Common Mistakes
- Review Checklist
- References
Architecture Overview
AppMigrationKit operates through three layers:
- App extension -- An
AppMigrationExtensionconforming type that the system invokes during migration. It handles data export and import. - System orchestration -- The OS manages the device-to-device session, transport, and scheduling. The extension does not control when it runs.
- Containing app -- After migration completes, the app checks
MigrationStatus.importStatuson first launch to determine whether migration occurred and whether it succeeded.
Key types:
| Type | Role |
|---|---|
| AppMigrationExtension | Protocol for the app extension entry point |
| ResourcesExportingWithOptions | Protocol for exporting files via archiver |
| ResourcesExporting | Simplified export protocol (no custom options) |
| ResourcesImporting | Protocol for importing files on the destination |
| ResourcesArchiver | Streams files into the export archive |
| MigrationDataContainer | Access to the containing app's data directories |
| MigrationStatus | Check import result from the containing app |
| MigrationPlatform | Identifies the other device's platform (e.g., .android) |
| MigrationAppIdentifier | Identifies the source app by store and bundle ID |
| AppMigrationTester | Test-only actor for validating export/import logic |
Setup and Entitlements
Entitlement
The app extension requires the com.apple.developer.app-migration.data-container-access
entitlement. Its value is a single-element string array containing the bundle
identifier of the containing app:
<key>com.apple.developer.app-migration.data-container-access</key>
<array>
<string>com.example.myapp</string>
</array>
No other values are valid. This entitlement grants the extension read access to the containing app's data container during export and write access during import. The entitlement itself is available on iOS 26.1+, iPadOS 26.1+, and Mac Catalyst 26.1+, even though the core AppMigrationKit APIs are available on iOS 26.0+ and iPadOS 26.0+.
Extension Target
Add a new App Extension target to the Xcode project. The extension conforms
to one or more of the migration protocols (ResourcesExportingWithOptions,
ResourcesExporting, ResourcesImporting).
App Migration Extension
The extension entry point conforms to AppMigrationExtension. During
migration, the system prevents launching the containing app and its other
extensions to ensure exclusive data access.
Accessing the Data Container
The extension accesses the containing app's files through appContainer:
import AppMigrationKit
struct MyMigrationExtension: ResourcesExporting {
var resourcesSizeEstimate: Int { estimateTotalExportSize() }
var resourcesVersion: String { "1.0" }
var resourcesCompressible: Bool { true }
func exportResources(
to archiver: sending ResourcesArchiver,
request: MigrationRequest
) async throws {
let container = appContainer
// container.bundleIdentifier -- app's bundle ID
// container.containerRootDirectory -- root of the app container
// container.documentsDirectory -- Documents/
// container.applicationSupportDirectory -- Application Support/
}
}
MigrationDataContainer provides containerRootDirectory, documentsDirectory,
and applicationSupportDirectory as URL values pointing into the containing
app's sandbox.
Exporting Resources
Conform to ResourcesExportingWithOptions (or ResourcesExporting for no
custom options) to package files for transfer. The system calls
exportResources(to:request:) with a ResourcesArchiver and a
MigrationRequestWithOptions.
Declaring Export Properties
struct MyMigrationExtension: ResourcesExportingWithOptions {
typealias OptionsType = MigrationDefaultSupportedOptions
var resourcesSizeEstimate: Int {
// Return estimated total bytes of exported data
calculateExportSize()
}
var resourcesVersion: String {
"1.0"
}
var resourcesCompressible: Bool {
true // Let the system compress during transport
}
}
resourcesSizeEstimate-- Estimated total bytes. The system uses this for progress UI and free-space checks.resourcesVersion-- Format version string. The import side receives this to handle versioned data formats.resourcesCompressible-- Whentrue, the archiver may compress files during transport.
Implementing Export
func exportResources(
to archiver: sending ResourcesArchiver,
request: MigrationRequestWithOptions<MigrationDefaultSupportedOptions>
) async throws {
let docsDir = appContainer.documentsDirectory
// Check destination platform if needed
if request.destinationPlatform == .android {
// Platform-specific export logic
}
// Append files one at a time -- make continuous progress
let userDataURL = docsDir.appending(path: "user_data.json")
try await archiver.appendItem(at: userDataURL)
// Append with a custom archive path
let settingsURL = docsDir.appending(path: "settings.plist")
try await archiver.appendItem(at: settingsURL, pathInArchive: "preferences/settings.plist")
// Append a directory
let photosDir = docsDir.appending(path: "photos")
try await archiver.appendItem(at: photosDir, pathInArchive: "media/photos")
}
The archiver streams files incrementally. Call appendItem(at:pathInArchive:)
repeatedly as each resource is ready. The system may terminate the extension
if it appears hung, so avoid long gaps between append calls.
Cancellation
ResourcesArchiver handles task cancellation automatically by throwing
cancellation errors. Do not catch these errors -- doing so causes the system
to kill the extension.
Migration Platform
MigrationRequestWithOptions exposes destinationPlatform as a
MigrationPlatform value. Use this to tailor exported data:
if request.destinationPlatform == .android {
// Export in a format the Android app expects
}
MigrationPlatform provides .android as a static constant. Custom
platforms can be created with MigrationPlatform("customPlatform").
Importing Resources
Conform to ResourcesImporting to receive transferred files on the
destination device. The system calls importResources(at:request:) after
app installation but before the app is launchable.
struct MyMigrationExtension: ResourcesImporting {
func importResources(
at importedDataURL: URL,
request: ResourcesImportRequest
) async throws {
let sourceVersion = request.sourceVersion
let sourceApp = request.sourceAppIdentifier
// sourceApp.platform -- e.g., .android
// sourceApp.bundleIdentifier -- source app's bundle ID
// sourceApp.storeIdentifier -- e.g., .googlePlay
// Copy imported files into the app container
let docsDir = appContainer.documentsDirectory
let userData = importedDataURL.appending(path: "user_data.json")
if FileManager.default.fileExists(atPath: userData.path()) {
try FileManager.default.copyItem(
at: userData,
to: docsDir.appending(path: "user_data.json")
)
}
}
}
Error Handling During Import
On import error, the system clears the containing app's data container to prevent partial state. However, app group containers are not cleared. The import implementation should clear any app group containers before writing imported content:
func importResources(
at importedDataURL: URL,
request: ResourcesImportRequest
) async throws {
// Clear shared app group data first
let groupURL = FileManager.default.containerURL(
forSecurityApplicationGroupIdentifier: "group.com.example.myapp"
)
if let groupURL {
try? FileManager.default.removeItem(at: groupURL.appending(path: "shared_data"))
}
// Then import
try await performImport(from: importedDataURL)
}
Source App Identifier
ResourcesImportRequest provides sourceAppIdentifier as a
MigrationAppIdentifier with three properties:
platform-- The source device's platform (e.g.,.android)bundleIdentifier-- The source app's bundle identifierstoreIdentifier-- The app store (e.g.,.googlePlay)
Migration Status
After migration completes, the containing app checks the result on first launch:
import AppMigrationKit
func application(
_ application: UIApplication,
didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
) -> Bool {
if let status = MigrationStatus.importStatus {
switch status {
case .success:
showMigrationSuccessUI()
MigrationStatus.clearImportStatus()
case .failure(let error):
showMigrationFailureUI(error: error)
MigrationStatus.clearImportStatus()
}
}
return true
}
MigrationStatus.importStatusisnilif no migration occurred.- Call
clearImportStatus()after handling the result to prevent showing the notification on subsequent launches. - The enum has two cases:
.successand.failure(any Error).
Progress Tracking
The import side exposes a Progress object via resourcesImportProgress.
The system uses this to display transfer progress to the user. Update
completedUnitCount incrementally during import:
struct MyMigrationExtension: ResourcesImporting {
private let importProgress = Progress(totalUnitCount: 100)
var resourcesImportProgress: Progress { importProgress }
func importResources(
at importedDataURL: URL,
request: ResourcesImportRequest
) async throws {
let files = try FileManager.default.contentsOfDirectory(
at: importedDataURL, includingPropertiesForKeys: nil
)
let increment = Int64(100 / max(files.count, 1))
for file in files {
try processFile(file)
importProgress.completedUnitCount += increment
}
importProgres
Truncated for display — read the full file on GitHub.
Related Skills
taste-skill
116.8kAgent skills that give coding agents taste: art direction, reference images and a browser check instead of generic AI pages
ai-job-search
72.1kThe job search that runs on your machine. AI job application framework built on Claude Code: evaluate postings, tailor CVs, write cover letters, prep interviews. Fork it and own it.
claude-howto
47.3kA visual, example-driven guide to Claude Code — from basic concepts to advanced agents, with copy-paste templates that bring immediate value.
lobehub
85.6k🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.
Languages
Trust signals
From repository metadata: license, adoption, age and documentation. Not a code audit — see the Safety scan above for what the skill file itself contains.
