The Error
After enabling HealthKit in your Despia editor and triggering a rebuild, Xcode fails with a code signing or capability error. Common error messages:Why This Happens
Enabling HealthKit in Despia is only half the setup. When you toggle HealthKit on in the Despia editor, it adds the HealthKit entitlement to your app’s code. But Apple also requires that your App ID (bundle identifier) has HealthKit enabled in the Apple Developer portal. If your bundle ID doesn’t have HealthKit capabilities enabled at the Apple Developer level, the build will fail because:- Your provisioning profile doesn’t include HealthKit permissions
- There’s a mismatch between what your app claims it can do and what Apple has authorized
The Solution
Enable HealthKit capabilities in Apple Developer for your bundle ID.Step 1: Go to Apple Developer
- Open Apple Developer
- Navigate to Certificates, Identifiers & Profiles
- Click Identifiers in the sidebar
- Find and click on your app’s bundle identifier
Step 2: Enable HealthKit Capabilities
- Scroll down to the Capabilities section
- Check the box for HealthKit
- Important: Also check HealthKit (Recalibrate Estimates)
- Click Save at the top right
Step 3: Rebuild Your App
- Go back to your Despia editor
- Trigger a new build
- The build should now succeed
Quick Checklist
Before rebuilding after enabling HealthKit:- HealthKit enabled in Despia editor
- HealthKit enabled in Apple Developer portal for your bundle ID
- HealthKit Recalibrate Estimates enabled (if using workout/activity features)
- Saved changes in Apple Developer portal
Still Having Issues?
If you’re still seeing capability errors after following these steps:- Clear old provisioning profiles - Sometimes Apple needs a fresh profile to pick up the new capabilities (if old ones are deleted Despia will issue new ones automatically)
- Check your bundle ID - Make sure the bundle ID in Despia matches exactly with Apple Developer
- Wait a few minutes - Apple’s systems can take a moment to propagate changes
- Your build error logs
- Screenshot of your HealthKit settings in both Despia and Apple Developer