You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
app.start.cold / app.start.warm → allow nesting; or make it be controlled somehow #5936
Currently, app.start.cold / app.start.warm is a flat child span of the root transaction. Native sub-spans (UIKit init, etc.) and JS Bundle Execution are children of it, but there's no way for user code to add custom child spans to the app start span.
Allowing nesting / control would be useful for:
Granular app start breakdown — Users could instrument their own initialization phases as child spans of app.start.cold:
app.start.cold > fetch_remote_config
app.start.cold > hydrate_cache
app.start.cold > auth_token_refresh
app.start.cold > initialize_feature_flags This gives real visibility into what's slow during cold start, not just the total duration.
Custom "control" of the app start span — If app.start.cold were exposed as an active span that users can reference, they could:
Add attributes/tags to it (e.g., app_version, launch_source)
Set custom start/end times
Decide when it actually ends (ties into idea 1)
Framework-level instrumentation — Libraries like Redux, React Navigation, Apollo Client, or Expo modules could automatically create child spans of app start, giving SDK users out-of-the-box breakdowns without manual work.
Matching native SDK capabilities — Android and iOS native Sentry SDKs already provide richer app start span trees with nested native phases. Allowing the RN layer to nest its own spans would create a unified, end-to-end app start waterfall from native init → JS bundle → React render → app ready.
See iOS/Android issues for more details around the new API. I think we can repurpose this issue to implement that API first, which will make it possible to customize the app start span as you see fit, e.g.:
// Must be called before the first frame is drawnconstlaunchSpan=Sentry.extendAppLaunch();// 1. Granular breakdown — attach child spans to app.start.coldconstconfigSpan=launchSpan?.startChild({name: "fetch_remote_config",op: "app.init"});awaitfetchRemoteConfig();configSpan?.finish();constcacheSpan=launchSpan?.startChild({name: "hydrate_cache",op: "app.init"});awaithydrateCache();cacheSpan?.finish();constauthSpan=launchSpan?.startChild({name: "auth_token_refresh",op: "app.init"});awaitrefreshAuthToken();authSpan?.finish();constflagsSpan=launchSpan?.startChild({name: "initialize_feature_flags",op: "app.init"});awaitinitFeatureFlags();flagsSpan?.finish();// 2. Custom attributes on the app start span itselflaunchSpan?.setAttribute("app_version","1.4.2");launchSpan?.setAttribute("launch_source","push_notification");// 3. Framework-level instrumentation (e.g. inside Redux enhancer)constreduxSpan=launchSpan?.startChild({name: "redux_store_init",op: "app.init.redux"});conststore=configureStore({ reducer });reduxSpan?.finish();// Mark the app as launched (or let it default to firstFrameDrawn)launchSpan?.finish();// Optional: separately mark full display (e.g. after data is rendered)launchSpan?.fullyDisplayed();
Activity
linear-code commentedon Mar 31, 2026
RN-566
romtsn commentedon Apr 17, 2026
See iOS/Android issues for more details around the new API. I think we can repurpose this issue to implement that API first, which will make it possible to customize the app start span as you see fit, e.g.:
github-actions commentedon Jul 9, 2026
A PR closing this issue has just been released 🚀
This issue was referenced by PR #6392, which was included in the 8.18.0 release.