Product Benefits Pricing Guides Docs About Contact us Try it out
Performance

Sentry Cocoa MetricKit Metric Reports Tracking

Sentry Cocoa 9.32 and 9.33 send MetricKit metrics as Sentry metrics. Learn MetricKit metric reports tracking for iOS CPU, memory and hitches.

· 3 min read

Crash reports tell you an app broke. They say nothing about the apps that slowly get heavier, hotter or hungrier until users quietly stop opening them. Without field data on CPU time, memory and network transfer, you only find these problems in a bad App Store review.

Sentry Cocoa 9.32.0 (29 October 2026) added enabledMetricReports, which sends Apple’s MetricKit metrics to Sentry as metrics named metrickit.<group>.<name>. Version 9.33.0 (4 November 2026) extended this on iOS and macOS 27 and later with animation hitch and Metal reports, and dropped the animationScrollHitchTimeRatio metric because MetricKit only reports the total hitch time of all animations.

One catch: 9.33.0 added new cases to the experimental SentryMetricKit.MetricReport enum. If your code uses an exhaustive switch, it will not compile until you handle them.

Data Points to Track

  • metrickit.cpu.cpu_time per app version
  • metrickit.memory.peak_memory_usage
  • metrickit.network.cellular_upload / cellular_download
  • metrickit.app_exit.* counts (normal, watchdog, memory limit)
  • metrickit.animation.hitch_time on iOS 27 and later
  • sentry_cocoa_version and os_version
  • device_model and low_power_mode
  • app_version and build_number

Setup Steps

  1. Upgrade to Sentry Cocoa 9.33.0 or later in a beta build.
  2. Fix any exhaustive switch over MetricReport by adding a default case.
  3. Set enabledMetricReports to the groups you need, such as CPU, memory and app exits. Start narrow.
  4. Keep enabledDiagnosticReports switched on if you also want crash and launch diagnostics.
  5. Tag the SDK and OS version so you can separate platform changes from your own.
  6. Build a dashboard with p50 and p95 per app version.
  7. Set alerts on regressions between releases, not on absolute numbers.

Actionable Insights

MetricKit data arrives as daily summaries from real devices, so it suits release-over-release comparison rather than live alerting. A p95 CPU time that rises after a release points to a regression your lab tests missed.

Watch app exit counts closely. A growing share of memory-limit or watchdog exits means users are losing sessions without a crash report to show for it.

Do not compare hitch metrics across the iOS 27 boundary. The way hitches are reported changed, so split charts by OS major version.

Finally, keep volume in mind. More metric groups mean more events, so enable only the ones you will act on.

Common Mistakes to Avoid

Do not expect real-time data. MetricKit delivers aggregated payloads from the previous day, so a fix shipped today will not show in the charts until tomorrow at the earliest.

Do not average across devices. An iPhone 12 and a recent Pro model behave very differently, so always segment by device model before deciding a release is slower. Small samples on rare devices will swing wildly, so set a minimum user count before you act on a chart.

Do not forget privacy. MetricKit data is aggregate and device-level, but if you join it with user IDs, tell users in your privacy notice.