37

I am new in Android Studio so I face some problem with it. I am looking for a way how to project clean.

In Eclipse I would do Project -> Clean -> OK but I don't know how it is done with Android Studio.

halfer
  • 19,471
  • 17
  • 87
  • 173
Mansukh Ahir
  • 3,833
  • 5
  • 38
  • 61

2 Answers2

81

You can clean your project doing this

Build > Clean Project or Build > Rebuild Project

Also you can do the gradlew clean

enter image description here

As @Kellogs commented :

Manually delete the [project]/.gradle as hidden folder as that one is the main culprit for large cleaned projects sizes.

Skizo-ozᴉʞS
  • 18,460
  • 17
  • 76
  • 134
  • 2
    and don't forget to manually delete the [project]/.gradle hidden folder as that one is the main culprit for large cleaned projects sizes. – kellogs Jan 21 '16 at 01:39
  • @kellogs Added an edit, if you think it needs more explination feel free to edit :) – Skizo-ozᴉʞS Jan 22 '16 at 11:23
21

Cleaning an android project is quite simple just follow these steps

1. Click on Gradle pane,found in the top-right corner of Android Studio 
2. Click on your project,then Tasks -> build ->clean

Step 1

enter image description here

Step 2

enter image description here

Note Never clean your project using the Build -> Clean Project.Instead of cleaning your project it will increase the size of it.

Update clean has been replaced by cleanBuildCache in the recent versions of Android Studio.

Mickaël Leger
  • 3,370
  • 2
  • 14
  • 36
Surbhit Rao
  • 555
  • 5
  • 13