Question

[Solved] 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

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.

Enquirer: Naveen

||

Solution #1:

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!

Respondent: Naveen

Solution #2:

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.
Respondent: Irina Cososchi

Solution #3:

5.5.1 is out now, try upgrading to that using ./gradlew wrapper --gradle-version=5.5.1 and see if that makes a difference. This is preferable to editing any Gradle files manually.

Respondent: Ananta Prasad

Solution #4:

Open your gradle-wrapper.properties and modify your distributionUrl to point to gradle-5.4.1-all.zip, i.e.

distributionUrl=https://services.gradle.org/distributions/gradle-5.4.1-all.zip

Change classpath to 3.5.0

buildscript {
    repositories {
        google()
        jcenter()

    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.5.0'
        ...
    }
}
Respondent: ditn

Solution #5:

For me, i re-downloaded the new and latest version of android studio, installed it full.
that solved the problem for me.

Respondent: shizhen

Solution #6:

download gradle 5.4.1 manually from https://downloads.gradle-dn.com/distributions/gradle-5.4.1-all.zip and extract the file and please it in .gralde file in your android project.
then restart the android studio

Respondent: N-Alli

Solution #7:

In case the complete error message is something like:

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

You need to delete two files( under your .gradle/wrapper/dists/* directory):

  • gradle-5.4.1-all.zip
  • gradle-5.4.1-all.zip.lck

Then try again to download dependencies or upgrade.

Respondent: Mallik Rajini

Solution #8:

From: classpath 'com.android.tools.build:gradle:3.2.1'

To: classpath 'com.android.tools.build:gradle:3.5.0'

And the gradle version:

distributionUrl=https://services.gradle.org/distributions/gradle-6.1.1-all.zip

GL

Respondent: Estuardolh

Solution #9:

  1. Close your Android Studio, whatever version you are using.
  2. Start it again with administrative log in.
  3. Android Studio will detect what needs to be updated or downloaded.

Automatically it will resolve the issue.

Respondent: Braian Coronel

The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .

Most Popular

To Top
India and Pakistan’s steroid-soaked rhetoric over Kashmir will come back to haunt them both clenbuterol australia bossier man pleads guilty for leadership role in anabolic steriod distribution conspiracy