Software⏱️ 3 min read📅 2026-06-04

How to Fix: NDK Resolution Outcome: Project settings: Gradle model version=5.4.1, NDK version is UNKNOWN error

NDK Resolution Outcome: Project settings: Gradle model version=5.4.1, NDK version is UNKNOWN error after updating Android Studio and Gradle.

Quick Answer: Try updating the NDK to a compatible version with Gradle 3.5 or use the 'ndk' task in build.gradle to specify the NDK path.

The error 'NDK Resolution Outcome: Project settings: Gradle model version=5.4.1, NDK version is UNKNOWN' occurs when Android Studio and Gradle are updated to versions 3.5, causing issues with the NDK (Native Development Kit) configuration.

This issue affects developers who rely on the latest updates of Android Studio and Gradle for their projects, resulting in frustration due to the inability to compile and run native code.

💡 Why You Are Getting This Error

  • The primary reason for this error is that the NDK version has not been updated or configured correctly with the new versions of Android Studio and Gradle. This can happen when the Gradle model version is set to 5.4.1, but the NDK version remains unknown.
  • Another possible cause could be a mismatch between the Android Studio and Gradle versions installed on the system.

🛠️ Step-by-Step Verified Fixes

Updating the Gradle model version to match the NDK version

  1. Step 1: Open the build.gradle file in your project and update the 'ndkVersion' property to match the actual NDK version.
  2. Step 2: If you are still unable to determine the correct NDK version, try checking the Android Studio output for any clues or use the 'ndk --version' command in the terminal.
  3. Step 3: Once the correct NDK version is identified, update the Gradle model version to 5.4.1 by adding the following line to the build.gradle file: ndk { version '5.4.1' }' and then sync the project.

Manually specifying the NDK path

  1. Step 1: If updating the Gradle model version does not resolve the issue, try manually specifying the NDK path in your build.gradle file.
  2. Step 2: Add the following line to the 'build.gradle' file: ndk { path 'path/to/ndk' }', replacing 'path/to/ndk' with the actual location of your NDK installation.

🎯 Final Words

To resolve the 'NDK Resolution Outcome: Project settings: Gradle model version=5.4.1, NDK version is UNKNOWN' error, update the Gradle model version to match the NDK version or manually specify the NDK path in your build.gradle file. If you are still experiencing issues, check for any system updates and ensure that all dependencies are correctly configured.

Did this fix your problem?

If not, try searching for specific error codes.

🔍 Search Error Database

❓ Frequently Asked Questions