Building Observable Android Performance: TTFR, TTI, and User Intent
Android performance monitoring has traditionally focused on crashes and ANRs, but the real user experience lies in the gap between app launch and meaningful interaction. This post explores building comprehensive performance observability that captures Time to First Render (TTFR), Time to Interactive (TTI), and crucially—the connection to user behavior.
The Problem with Traditional Metrics
Most Android performance tools give you:
- Crash rates (too late)
- ANR counts (catastrophic failures only)
- Cold start time (limited scope)
What they miss:
- How long until users see content
- How long until users can interact
- Why performance drops correlate with feature abandonment
A Better Approach: Intent-Aware Performance
class PerformanceInterceptor : NavigationInterceptor {
override fun onNavigationStart(destination: String, intent: UserIntent) {
performanceTracker.startTrace(
traceId = generateTraceId(),
destination = destination,
userIntent = intent,
timestamp = System.currentTimeMillis()
)
}
override fun onFirstRender(traceId: String) {
performanceTracker.markTTFR(traceId)
}
override fun onInteractive(traceId: String) {
performanceTracker.markTTI(traceId)
}
override fun onNavigationCancelled(traceId: String, reason: CancellationReason) {
performanceTracker.recordCancellation(traceId, reason)
}
}
Key Insights from Implementation
1. Pluggable Architecture
Different apps have different navigation patterns. The interceptor pattern allows teams to instrument their specific flows without coupling to a rigid framework.
2. Cancellation Taxonomy
Not all performance issues result in completed flows. Tracking why users abandon actions provides crucial context:
- Back button (user choice)
- Network timeout (infrastructure)
- App backgrounded (interrupted)
3. Actionable Budgets
Raw metrics don't drive decisions. Setting performance budgets tied to business outcomes does:
- TTFR < 200ms for checkout flows
- TTI < 500ms for search results
- <5% cancellation rate for core journeys
Results and Next Steps
Early implementation shows 40% reduction in performance-related user drop-offs when teams can correlate slow renders with specific user journeys. The next phase involves:
- Real-time alerting for budget violations
- A/B testing performance optimizations
- Predictive models for performance-driven churn
Performance observability isn't just about faster apps—it's about understanding how speed impacts user success.