When I open android studio I am getting an error- "Error loading project: Cannot load 2 facets. When I clicked to see the error the following appeared
"2 facets cannot be loaded. You can mark them them as ignored to suppress this error notification. Unknown facet type:'android', Unknown facet type:'android-gradle'
I tried to add facets ( In Project Structure > Project settings > Modules > clicked project name, then clicked Android as well as Android-Gradle) But both showed as "cannot load facet, unknown facet type." Under Project settings > Facets > both Android and Android-Gradle are displayed as 'Invalid facets'. My project was running smoothly. This problem occured when I force-closed my laptop before exiting android studio as everything got stuck. After that whenever I open the android studio this problem occurs. I am not able to run my project. Can anyone please help me to solve this?
In Android Studio go to
I faced this issue in Android Studio 3.2.1 I had to re-import my project after that it works.
Just enable
Android Support
plugin.Ctrl+Alt+S
in Windows orMeta+Comma
in Mac.Android Support
plugin, check it and clickOK
at the bottom of screen.This is how it looks:
This problem occured when i'd updated Android Studio.
In case nothing from other answers works, you don't have another option, except removing broken settings and making clean setup.
So what i am suggesting:
File, Then Settings->Plugin->Enable/Renable Plugin --> Apply --> Restart