Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-5.4.1-all.zip'

Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-5.4.1-all.zip'

I have just installed Android Studio 3.5 on windows and then created new project then above exception occurs. I have searched on google regarding the above error but none resolved.

Below are the links which I have tried but none worked

  • Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-2.1-all.zip'
  • Eclipse -Could not install Gradle distribution from 'https://services.gradle.org/distributions/gradle-2.1-bin.zip'

Is this issue is with Antivirus which is installed in local machine ?.I am just guessing, is this because of Antivirus ?

I was trying with this since 3 days.Please help me on this.Any help would be appreciated.

like image 270
Naveen Avatar asked Aug 22 '19 16:08

Naveen


People also ask

How do I setup Gradle in Windows 10?

Download Gradle and unzip it to where you want it installed. Click the Advanced system settings link. Then click New button under user variable and add GRADLE_HOME to variable name and path pointing to the root directory of unpacked files from the Gradle to variable value.

How do I know if Gradle is installed Mac?

Verify Gradle Installation. Now open the command prompt. In the command prompt, enter Gradle -version. It will display the current version of Gradle just installed on the screen.

Where is Gradle installed on Mac?

On Mac: /usr/local/opt/gradle/libexec in case you installed it via brew . For Windows: specify the path where you installed Gradle.


3 Answers

I had the same problem and eventually I figured out that running Android Studio as administrator solves it. You can at least give it a try!

like image 177
Irina Cososchi Avatar answered Oct 13 '22 21:10

Irina Cososchi


Steps to fix:

  1. Close Android studio.
  2. Right click on launcher icon of Android Studio
  3. Click on "Run as administrator"
  4. It will run like charm.
like image 39
Ananta Prasad Avatar answered Oct 13 '22 19:10

Ananta Prasad


Goto gradle-wrapper and see carefully the URL distributionUrl=https \ ://services.gradle.org/distributions/gradle-6.1.1-all.zip

now correct the https \ :// to https:// and click on "try again upside."

it will took download the file and run automatically. And after successful run promote thi$ answer.

like image 18
Aarif Husain Avatar answered Oct 13 '22 19:10

Aarif Husain