Help Center/ CodeArts Agent/ FAQs/ Code Repository Cloning/ What Should I Do If the message "Could not connect to server" Appears When Cloning a Git Repository?
Updated on 2026-07-27 GMT+08:00

What Should I Do If the message "Could not connect to server" Appears When Cloning a Git Repository?

Symptom

When you clone a remote repository using Git in CodeArts Agent IDE, the message "Could not connect to server" is displayed.

Cause Analysis

You are using the company intranet. Configure a proxy to ensure normal access.

Solution

Add the following content to the local C:\Users\username\.gitconfig file:

# HTTP proxy address. Replace https://***.com/ with the actual domain name prefix of the code repository.
[http "https://***.com/"]
# Disable SSL certificate verification.
    sslVerify = false
# Proxy-server-address:port-number
    proxy = http://***.com:8080
# HTTPS proxy address. Replace https://***.com/ with the actual domain name prefix of the code repository.
[https "https://***.com/"]
# Disable SSL certificate verification.
    sslVerify = false
# Proxy-server-address:port-number
    proxy = http://***.com:8080