Computer scienceMobileAndroidAndroid Core

Android development in IntelliJ IDEA

1 minute read

This guide will take you through setting up and working with Android projects (including Hyperskill Android projects) in IntelliJ IDEA. We will cover installing the necessary plugins, setting up the Android SDK, and configuring the correct JDK for your projects.

Required plugins

You first need to install two core plugins from the Jetbrains Marketplace:

Follow these steps to install them:

  1. Open the IDE settings using the default keyboard shortcut Ctrl+Alt+S (or by navigating to File > Settings).

  2. In the settings window, select the Plugins section.

    You can also navigate to plugins directly from the welcome window.

  3. Go to the Marketplace tab and use the search bar to find the "Android" and "Android Design Tools" plugins.

  4. Click the Install button for each one.

  5. After the installation is complete, restart your IDE if prompted.

    Android and Android Design Tools IntelliJ IDEA plugins

Set up the Android SDK

The Android SDK provides tools, libraries, and APIs required to build, test, and debug Android apps. If you already have Android Studio installed and configured on your machine, IntelliJ IDEA should be able to locate and use the existing SDK automatically, and you may skip this step.

If you are setting up from scratch, create a new Android project. IntelliJ IDEA will detect that the SDK is missing and will prompt you to download it. The setup wizard will pre-select all the required components for you. Simply confirm the installation path and proceed.

Configure project and Gradle JDK

When you open a Hyperskill Android project in IntelliJ IDEA, you’ll be prompted to choose a JDK version, make sure to select JDK 23. For compatibility, also ensure you’re using at least Gradle 8.10, since that’s the minimum supported version.

Follow the steps below to configure the versions.

  • Project JDK Configuration:

    1. Go to File > Project Structure > Project (under Project Settings).

    2. In the SDK dropdown menu, make sure version 23 is selected.

    3. If JDK 23 is not available, click + Add SDK > Download JDK... and select version 23 from the list to install it.

      Project JDK configuration

  • Gradle JDK Configuration:

    1. Open the settings and navigate to Build, Execution, Deployment > Build Tools > Gradle.

    2. In the Gradle JVM field, select the same JDK you configured for your project (version 23).

      Gradle JDK configuration

  • Gradle Version Configuration:

    1. From the project's root directory, navigate to the file "gradle/wrapper/gradle-wrapper.properties".

    2. Open it and locate the line that starts with distributionUrl=.

    3. Change the version part of the URL to specify version 8.10:

      distributionUrl=https\://services.gradle.org/distributions/gradle-8.10-bin.zip
    4. After making the changes, you should see the option to Sync Gradle Changes. If it doesn’t appear, go to Build > Sync Project with Gradle Files.

      Gradle's gradle-wrapper.properties file

Conclusion

IntelliJ IDEA should now be configured for Android development. You have the necessary plugins, the Android SDK, and properly configured JDK. With this, you are ready to tackle Hyperskill Android projects.

How did you like the theory?
Report a typo