https://developer.android.com/agents/skills/navigation/navigation-3/skill

Migrate Android Compose apps from Navigation 2 to Navigation 3.

5|Updated Feb 22, 2026
One-click install
npx skills add https://github.com/fornewid/android-developers-changelog --skill https-developer-android-com-agents-skills-navigation-navigation-3-skill
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: https://developer.android.com/agents/skills/navigation/navigation-3/skill
Source: https://github.com/fornewid/android-developers-changelog/tree/main/docs/agents/skills/navigation/navigation-3
Command: npx skills add https://github.com/fornewid/android-developers-changelog --skill https-developer-android-com-agents-skills-navigation-navigation-3-skill

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It helps you understand and apply the key changes required to move an existing Android app from Navigation 2 to Navigation 3 without breaking navigation flows, state restoration, or UI behavior.

Core Features & Use Cases

  • Migration guidance: Covers dependency updates, route changes, and state management differences between Navigation 2 and Navigation 3.
  • Type-safe navigation in Compose: Shows how to migrate from string-based destinations to Type-Safe Navigation with Jetpack Compose and Jetpack Navigation.
  • Practical navigation patterns: Provides recipes for common real-world needs such as multiple back stacks, deep links, Scenes (dialog/bottom sheet/custom layouts), conditional navigation, modularization with DI, and ViewModel argument passing and result returning.

Quick Start

Ask the AI to outline the exact steps to migrate your Compose navigation from Navigation 2 to Navigation 3 and include the recommended recipes for deep links and multiple back stacks.

Frequently Asked Questions about https://developer.android.com/agents/skills/navigation/navigation-3/skill

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate from Android Navigation 2 to Navigation 3 in Compose?

Migrating from Navigation 2 to Navigation 3 involves updating dependencies, changing routes, and adjusting state management to preserve existing navigation flows and UI behavior in your Compose app.

How does type-safe navigation work when migrating to Navigation 3?

Type-safe navigation in Navigation 3 replaces string-based destinations with strongly typed objects. This approach integrates with Jetpack Compose to provide compile-time safety for your navigation routes, arguments, and deep links.

Can I preserve multiple back stacks when moving to Navigation 3?

Yes, you can preserve multiple back stacks during your Navigation 3 migration. The transition includes specific recipes for handling back stack behaviors to maintain expected UI state and navigation flows across different tabs.

Does Navigation 3 support deep links and Scenes-based layouts?

Navigation 3 supports deep links and Scenes-based layouts for dialogs, bottom sheets, and custom layouts. The migration guide maps these specific patterns to ensure your UI components function correctly.

What is the best way to handle ViewModel argument passing in Navigation 3?

The best way to handle ViewModel argument passing in Navigation 3 is by using targeted recipe patterns. These patterns ensure correct argument passing and result returning while integrating with modularized DI navigation logic.

When should I not migrate to Navigation 3?

You should delay migrating to Navigation 3 if your app relies heavily on complex string-based destinations that cannot easily map to type-safe navigation, or if you lack the resources to test state restoration across multiple back stacks.