# java.lang.IllegalArgumentException: Navigation destination cannot be found for deep link: https://example.com/path

- **ID:** `android/navigation-unknown-deeplink-host`
- **Domain:** android
- **Category:** runtime_error
- **Verification:** ai_generated
- **Fix Rate:** 87%

## Root Cause

Navigation component cannot match a deep link URI to any registered destination in the NavGraph due to missing or malformed deep link declaration.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| Navigation 2.6.0 | active | — | — |
| Navigation 2.7.0 | active | — | — |
| Android 12 | active | — | — |
| Android 13 | active | — | — |

## Workarounds

1. **Add a `<deepLink app:uri="https://example.com/path" />` element inside the corresponding `<fragment>` or `<activity>` in your nav_graph.xml file.** (90% success)
   ```
   Add a `<deepLink app:uri="https://example.com/path" />` element inside the corresponding `<fragment>` or `<activity>` in your nav_graph.xml file.
   ```
2. **Verify the deep link URI pattern matches exactly, including path and query parameters. For dynamic paths, use placeholders like `{id}` in the URI.** (85% success)
   ```
   Verify the deep link URI pattern matches exactly, including path and query parameters. For dynamic paths, use placeholders like `{id}` in the URI.
   ```

## Dead Ends

- **** — Adding `<intent-filter>` in AndroidManifest.xml for the activity without corresponding <deepLink> in NavGraph causes mismatch. (80% fail)
- **** — Hardcoding the deep link URI in code without registering it in the NavGraph XML leads to the same error. (90% fail)
- **** — Using `app:uri` with incorrect scheme (e.g., 'http' instead of 'https') causes no match. (70% fail)
