engineering · Fresher-friendly
Android Developer interview questions on Activity lifecycle, Kotlin/Java, Jetpack components, and REST integration.
What are the four main components of an Android application?
Tip: Activity (UI screen), Service (background processing), BroadcastReceiver (system/app events), ContentProvider (shared data). Each is declared in `AndroidManifest.xml`. Interviewers often ask which to use for a given scenario.
Explain the Android Activity lifecycle. When is `onStop` called vs `onPause`?
Tip: `onPause`: activity is partially obscured (another activity in front). `onStop`: activity is fully hidden. `onDestroy`: activity is being destroyed. Save state in `onPause` (not `onStop`) for guaranteed execution.
What is the difference between Fragment and Activity?
Tip: Activity is a standalone screen. Fragment is a modular section of UI hosted inside an Activity — multiple fragments can share one Activity. Use Fragments for adaptive layouts (phone vs tablet) and Navigation Component.
What are Jetpack components? Name and explain three commonly used ones.
Tip: ViewModel: survives configuration changes, holds UI state. LiveData/StateFlow: observable data holder that respects lifecycle. Room: SQLite abstraction with compile-time query validation. Navigation Component: handles fragment transactions declaratively.
What are Kotlin coroutines? How do they differ from threads?
Tip: Coroutines are lightweight cooperative concurrency primitives — they suspend without blocking a thread. A single thread can run thousands of coroutines. Use `viewModelScope.launch {}` for ViewModel-scoped coroutines. Use `Dispatchers.IO` for I/O, `Dispatchers.Main` for UI updates.
What is RecyclerView? How does the ViewHolder pattern improve performance?
Tip: RecyclerView efficiently displays large lists by recycling views as they scroll off-screen. ViewHolder caches `findViewById` calls so they happen once, not on every bind. Without ViewHolder, `findViewById` is called for every visible item on every scroll.
Tell me about the Android app you are most proud of. What was the hardest technical problem you solved?
Tip: Be specific: describe the exact challenge (background sync, complex animation, offline mode, performance) and your solution. Mention the architecture pattern (MVVM, Clean Architecture) and the impact.
Your app crashes on Android 6 but works fine on Android 12. How do you debug?
Tip: Check runtime permissions introduced in API 23 (Android 6) — camera, location, storage all require explicit grants. Check min SDK vs API availability. Use `@RequiresApi` and version checks. Read the stack trace — the API class or method name often reveals the gap.
How do you ensure backward compatibility in your Android apps?
Tip: Use AndroidX libraries (they backport modern APIs). Check `minSdkVersion` before using any API. Use `@RequiresApi` for version-gated code. Test on emulators covering your min and max SDK targets.
What is `onSaveInstanceState`? When is it called and what should you save in it?
Tip: Called before an Activity is destroyed for configuration changes (rotation) or system-initiated process death. Save UI state that cannot be easily re-derived (scroll position, text field contents). Do NOT save large objects — use ViewModel for those (it survives rotation).
What is the difference between Intent and PendingIntent?
Tip: Intent: an immediate message to start an Activity/Service/BroadcastReceiver. PendingIntent: a token wrapping an Intent that can be executed later by the system (e.g. AlarmManager, Notification actions). PendingIntent carries your app's permissions to the recipient.
Native Android vs Flutter vs React Native — which do you prefer for a new project and why?
Tip: Native: best performance, full API access, larger job market in India. Flutter: single codebase, fast UI, growing adoption. React Native: JS bridge adds overhead but large web-dev talent pool. Your answer should reflect your actual experience.
Practice, not just reading
Upload your resume and practice a full Android Developer mock interview with AI-generated questions and rubric-based scoring across 5 dimensions — free to start.