capacitor-app-upgrade-v6-to-v7
Skill75 starsChanged 35 days agoMITView on GitHub
Upgrades a Capacitor app from v6 to v7 using `npx cap migrate` from `@capacitor/cli@latest-7`, then the manual checklist - Node 20+, Xcode 16+, iOS deployment target 14.0 (Xcode project and Podfile), Android Studio Ladybug with JDK 21, AGP 8.7.2, Gradle 8.11.1, minSdk 23, compile/target SDK 35, removed `bundledWebRuntime` and `cordova.staticPlugins` config, `navigation` in configChanges, and official plugin breaking changes (removed deprecated types like `AppUrlOpen`, `HapticsImpactStyle`, `DeviceBatteryInfo`; Device no longer returns disk sizes). Use when `@capacitor/core` is 6.x and the target is 7.x, or on errors like "Capacitor 7 requires JDK 21" or "Module 'X' has no exported member 'AppUrlOpen'". Do not use for other major versions, plugin library upgrades, or non-Capacitor apps.
- Installs packages
1 other project uses a version of this, 1 of them edited.
Adopted by
Most recently taken up by
- Aver005/agent-skillsedited, first seen Feb 14, 2026
Other versions1 project uses a version of this.
Word for word · 0
None found.
Edited · 1
- Aver005/agent-skills★ 232% same
Wrote their own version · 0
None found.
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository56 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- capacitor-accessibilitySkill
- capacitor-app-intentsSkill
- capacitor-apple-review-preflightSkill
- capacitor-app-storeSkill
- capacitor-app-upgradesSkill
- capacitor-app-upgrade-v4-to-v5Skill
- capacitor-app-upgrade-v5-to-v6Skill
- capacitor-app-upgrade-v7-to-v8Skill
- capacitor-app-upgrade-v8-to-v9Skill
- capacitor-best-practicesSkill
- capacitor-ci-cdSkill
- capacitor-deep-linkingSkill
- capacitor-ios-resizabilitySkill
- capacitor-ios-security-hardeningSkill
- capacitor-keyboardSkill
- capacitor-mcpSkill
- capacitor-offline-firstSkill
- capacitor-performanceSkill
- capacitor-plugin-spm-supportSkill
- capacitor-pluginsSkill
- capacitor-plugin-upgradesSkill
- capacitor-plugin-upgrade-v4-to-v5Skill
- capacitor-plugin-upgrade-v5-to-v6Skill
- capacitor-plugin-upgrade-v6-to-v7Skill
- capacitor-plugin-upgrade-v7-to-v8Skill
- capacitor-plugin-upgrade-v8-to-v9Skill
- capacitor-push-notificationsSkill
- capacitor-securitySkill
- capacitor-splash-screenSkill
- capacitor-testingSkill
- capacitor-uiscene-migrationSkill
- capawesome-live-update-migrationSkill
- capgo-cli-usageSkill
- capgo-cloudSkill
- capgo-live-updatesSkill
- capgo-native-buildsSkill
- capgo-organization-managementSkill
- capgo-release-managementSkill
- capgo-release-workflowsSkill
- cocoapods-to-spmSkill
- cordova-to-capacitorSkill
- debugging-capacitorSkill
- framework-to-capacitorSkill
- ionic-appflow-migrationSkill
- ionic-designSkill
- ionic-enterprise-sdk-migrationSkill
- ios-android-logsSkill
- konsta-uiSkill
- safe-area-handlingSkill
- skill-creatorSkill
- sqlite-to-fast-sqlSkill
- subscription-app-revenueSkill
- tailwind-capacitorSkill
- webapp-to-capacitorSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 2 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 31
Only load a reference when its topic is in play.
- Distinctive: line 59
Run the automated migration:
- Very specific: line 72
Update @capacitor/* plugins to ^7.0.0 and community plugins to their Capacitor 7 releases.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Capacitor App Upgrade v6 to v7
Move a Capacitor 6 app to Capacitor 7. Source of truth: https://capacitorjs.com/docs/updating/7-0
When to Use
@capacitor/corein the snapshot below is6.xand the user wants7.x.- Build fails after bumping to 7 with JDK 21 / AGP 8.7 errors, iOS deployment target 13 errors, or TypeScript errors on removed deprecated plugin types.
- The user asks for the exact 6 -> 7 checklist.
Do not use:
- App on 5.x ->
capacitor-app-upgrade-v5-to-v6first. On 7.x ->capacitor-app-upgrade-v7-to-v8. Multi-hop planning ->capacitor-app-upgrades. - Plugin library upgrade ->
capacitor-plugin-upgrade-v6-to-v7. - CocoaPods to SPM ->
cocoapods-to-spm.
Live Project Snapshot
Current Capacitor packages from package.json:
!node -e "const fs=require('fs');if(!fs.existsSync('package.json'))process.exit(0);const pkg=JSON.parse(fs.readFileSync('package.json','utf8'));const out=[];for(const section of ['dependencies','devDependencies']){for(const [name,version] of Object.entries(pkg[section]||{})){if(name.startsWith('@capacitor/'))out.push(section+'.'+name+'='+version)}}console.log(out.sort().join('\n'))"
References
Only load a reference when its topic is in play.
| File | Load when |
references/android.md | Editing variables.gradle, build.gradle, wrapper, manifest, or Kotlin by hand |
references/plugins.md | The app uses official @capacitor/* plugins (App, Device, Haptics, Splash Screen, Status Bar, ...) |
Preflight
| Tool | Minimum for Capacitor 7 |
| Node.js | 20+ (latest LTS recommended) |
| Xcode | 16.0+ |
| iOS deployment target | 14.0 |
| Android Studio | Ladybug 2024.2.1+ (bundles JDK 21) |
| Java (Gradle JDK) | 21 |
| AGP / Gradle | 8.7.2 / 8.11.1 |
| Android SDK | minSdk 23, compileSdk 35, targetSdk 35 |
node -v && xcodebuild -version && java -version
git status --short
grep -rn "bundledWebRuntime\|staticPlugins" capacitor.config.*Procedure
- Confirm 6.x from the snapshot. Note: dropping minSdk to 23 and iOS to 14 removes support for older devices; tell the user.
Run the automated migration:
npm i -D @capacitor/cli@latest-7 npx cap migrateIt bumps packages, raises the iOS deployment target and Podfile to 14.0, updates Gradle files and the wrapper, and runs
cap sync. Finish every step it reports as skipped or failed.- Config (
capacitor.config.*):bundledWebRuntimeis removed.false-> delete it.true-> the app must bundle@capacitor/corewith a bundler (Vite, webpack, ...) instead of loadingcapacitor.js.cordova.staticPluginsis removed. Cordova plugins that need static linking must use apodspectag withuse-framework(cordova-ios 7+ does not support theframeworktag).
- iOS: set iOS Deployment Target = 14.0 on the Project and every Target in Build Settings, and
platform :ios, '14.0'inios/App/Podfile. For SPM apps, checkCapApp-SPM/Package.swiftplatforms. - Android: apply
references/android.md(AGP 8.7.2, Gradle 8.11.1, google-services 4.4.2, Kotlin 1.9.25, optionalnavigationinconfigChanges). - Update
@capacitor/*plugins to^7.0.0and community plugins to their Capacitor 7 releases. Fix removed types perreferences/plugins.md. - Telemetry is opt-out for new CLI users; it never runs in CI. Disable with
npx cap telemetry offif the user wants. - Run verification.
Traps
- JDK 21 is required: Capacitor 7 Android modules compile with Java 21 source/target, so a JDK 17 Gradle runtime fails with
invalid source release: 21. Fix the Gradle JDK (IDE and CI), not the code. - Community plugins still declaring
minSdkVersion 22or iOS 13 compile, but plugins that declare@capacitor/corepeer^6cause npmERESOLVE. Upgrade or replace them; avoid--legacy-peer-depsunless the user accepts the risk. - Device
getInfo()no longer returnsdiskFree,diskTotal,realDiskFree,realDiskTotal. Remove the matchingPrivacyInfo.xcprivacydisk-space entries only if no other code reads disk space.
Verification
grep -rn "bundledWebRuntime\|staticPlugins" capacitor.config.* # expect none
grep -rn "IPHONEOS_DEPLOYMENT_TARGET" ios/App/App.xcodeproj/project.pbxproj | sort -u # 14.0
grep -n "platform :ios" ios/App/Podfile 2>/dev/null # '14.0'
grep -n "gradle:8.7.2\|google-services:4.4.2" android/build.gradle
grep -n "distributionUrl" android/gradle/wrapper/gradle-wrapper.properties # gradle-8.11.1
grep -n "SdkVersion" android/variables.gradle # 23 / 35 / 35
grep -rnE "AppUrlOpen|AppRestoredResult|DeviceBatteryInfo|DeviceLanguageCodeResult|Haptics(Impact|Notification)(Options|Type|Style)|SplashScreen(Show|Hide)Options|diskFree|diskTotal" src/
npx cap sync
cd android && ./gradlew assembleDebugThen build iOS in Xcode 16+ and launch both platforms.
Error Handling
| Error | Fix |
Migrate can only be used on Capacitor 6, please use the CLI in Capacitor 6 to upgrade to 6 first | Run capacitor-app-upgrade-v5-to-v6 first. |
Capacitor 7 requires JDK 21 or higher. Some steps may fail. / invalid source release: 21 | Set Gradle JDK to 21 (Android Studio Ladybug bundles it) and in CI. |
Skipped updating deployment target | Set iOS 14.0 manually in Xcode and Podfile (step 4). |
Unable to find "<text>" in <file>. Try updating it manually | Apply the diff from references/android.md. |
Module '"@capacitor/app"' has no exported member 'AppUrlOpen' (or similar) | Rename to the replacement type in references/plugins.md. |
ERESOLVE unable to resolve dependency tree on @capacitor/core | A plugin still peers on v6; upgrade it to its v7 release. |
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

