/docs/integrations/Crashlytics.md in the projectWhat is Crashlytics?
Crash Reports
Error Tracking
User Privacy
Free Tier
Step-by-Step Setup
Step 1: Go to Firebase Console
Step 2: Name Your Project
Step 3: Disable Analytics (Optional)
Step 4: Add iOS App
Step 5: Register Your App
Step 6: Download GoogleService-Info.plist
GoogleService-Info.plist file. Add it to your Xcode project root and make sure it’s added to your target.- ✅ Check “Copy items if needed”
- ✅ Select your app target
Step 7: Add Firebase SDK
Step 8: Add via Swift Package Manager
Step 9: Add Initialization Code
App.swift or AppDelegate:Step 10: Add Linker Flags
-ObjC to Other Linker Flags. This is required for Firebase to work correctly with Swift.Step 11: Add Run Script Phase
- Click + → New Run Script Phase
- Name it “Upload dSYMs to Crashlytics”
- Add the upload script (see Firebase docs)
Step 12: Configure Input Files
Step 13: Complete Run Script Setup
Step 14: Set Debug Information Format
DWARF with dSYM File for Release builds. This generates the debug symbols needed for crash reports.Step 15: Add Test Crash Code
Step 16: Test on Real Device
Step 17: Verify in Dashboard
How It Works
Automatic Integration
The boilerplate includes a CrashReporter protocol that automatically switches between Firebase Crashlytics and NoOp based on availability:crashlyticsEnabled is off in DEBUG and reads the CRASHLYTICS_ENABLED environment variable in Release (FeatureFlags.swift). Add the plist and flip the flag — no other code changes needed.
User Privacy
Users control crash reporting in Settings → Share Diagnostics:- ✅ ON → Crashes sent to Firebase
- ❌ OFF → No data sent
- Never sends email addresses
- User has opt-out control
- Clear privacy disclosure
What Gets Tracked
Automatically
- Crash reports with stack traces
- Device info (model, iOS version)
- App version
- User ID (anonymized, no email)
- Session info
Custom (Optional)
- Non-fatal errors
- Custom logs/breadcrumbs
- User attributes (subscription tier, theme, etc.)
Viewing Reports
Firebase Console:- Go to Firebase Console
- Select your project
- Crashlytics (in sidebar)
- View crashes, errors, logs
- Stack traces
- Device information
- User ID
- App version
- Custom logs
Cost
Firebase Free Tier:- ✅ Unlimited crash reports
- ✅ 30-day retention
- ✅ Basic analytics
- ✅ Enough for most apps
- Extended retention
- More features
- Pay as you go (very low cost)
Troubleshooting
Crashes not appearing in dashboard
Crashes not appearing in dashboard
- Make sure you tested on a real device, not simulator
- Relaunch the app after the crash to send the report
- Wait a few minutes for the report to appear
- Check that
GoogleService-Info.plistis in your target
Symbolication not working
Symbolication not working
- Verify dSYM upload script is running
- Check that Debug Information Format is set to
DWARF with dSYM File - Ensure input files are configured correctly
Build errors after adding Firebase
Build errors after adding Firebase
- Make sure
-ObjCis in Other Linker Flags - Clean build folder (⌘⇧K) and rebuild
- Check that you only added FirebaseCrashlytics package
Related Guides
Full Integration Guide
/docs/integrations/Crashlytics.mdFeature Flags
Composition/FeatureFlags.swiftSettings Module
Privacy Policy
Resources/privacy.md to mention crash reportingNeed Help?
The boilerplate handles all the integration automatically. You just need to:- Add
GoogleService-Info.plist - Enable feature flag
- Build and run
/docs/integrations/Crashlytics.md.