Importing a Gradle project into IntelliJ

Well, this should be easy, but as usual in practical software engineering it often is not. So, here is my recipe for importing gradle projects into IntelliJ.

Panic Button

The standard answer in software engineering when systems behave weird is reboot. I have had to reboot intellij gradle projects quite a few times. So here is a recipe.

  1. Close the project in IntelliJ.
  2. On the Welcome screen, click the 'X' / delete icon, next to the project name. Ensure that the project is gone from the Welcome screen.
  3. Open a shell, go to the project root folder, and remove folder '.idea' and possible file '(project).iml', to ensure all IntelliJ files are deleted.
  4. Now, repeat the import procedure for the project.


Henrik Bærbak Christensen - Aarhus University