I have the latest Android Studio IDE installed on my Windows 10 laptop, and it was working fine until my windows operating system made a huge automatic update.
Now,
Editing global gradle.properties with the following line was the fix for me:
gradle.properties
org.gradle.jvmargs=-Dorg.gradle.internal.http.connectionTimeout=120000 -Dorg.gradle.internal.http.socketTimeout=120000