# Why is git cloning so absolutely difficult? Why not just provide HTTPS?

**URL:** <https://discuss.huggingface.co/t/why-is-git-cloning-so-absolutely-difficult-why-not-just-provide-https/165096>\
**Category:** Beginners\
**Created:** [July 30, 2025, 7:10pm UTC](https://discuss.huggingface.co/t/why-is-git-cloning-so-absolutely-difficult-why-not-just-provide-https/165096 "2025-07-30T19:10:44Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mindph](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/mindph/32/51902_2.png) [@mindph](https://discuss.huggingface.co/u/mindph)\
**Post date:** [July 30, 2025, 7:10pm UTC](https://discuss.huggingface.co/t/why-is-git-cloning-so-absolutely-difficult-why-not-just-provide-https/165096/1 "2025-07-30T19:10:44Z")

</div>

I thought cloning HF repos might be just like github or gitlap etc but instead I need to create some keys and stuff? And the [documentation](https://huggingface.co/docs/hub/en/models-downloading) is also not really clear on this…

```auto
[u]$ git lfs install
Git LFS initialized.
[u]$ git clone git@hf co...
Cloning into ...
git@hf co: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

```

---

<div class="post-metadata">

**Author:** ![John6666](https://sea2.discourse-cdn.com/hellohellohello/user_avatar/discuss.huggingface.co/john6666/32/27664_2.png) [@John6666](https://discuss.huggingface.co/u/John6666)\
**Post date:** [July 30, 2025, 9:30pm UTC](https://discuss.huggingface.co/t/why-is-git-cloning-so-absolutely-difficult-why-not-just-provide-https/165096/2 "2025-07-30T21:30:48Z")

</div>

The error message seems to indicate an SSH error…

> **[Git over SSH](https://huggingface.co/docs/hub/en/security-git-ssh)**
>
> We’re on a journey to advance and democratize artificial intelligence through open source and open science.

> [@Git@hf.co: Permission denied (publickey)](https://discuss.huggingface.co/t/git-hf-co-permission-denied-publickey/88452):
>
> I am having trouble authenticating with my SSH key when trying to access a Hugging Face Git repository. When I attempt to connect, I receive the following error message: git@hf.co: Permission denied (publickey). I have provided more detailed debug information of ssh -vvvT git@hf.co below: debug1: Next authentication method: publickey debug1: get\_agent\_identities: bound agent to hostkey debug1: get\_agent\_identities: agent returned 1 keys debug1: Will attempt key: /Users/kenshin/.ssh/hf\_id ED25…

> [@Unable to clone repository via ssh](https://discuss.huggingface.co/t/unable-to-clone-repository-via-ssh/79478):
>
> I followed [Git over SSH](https://huggingface.co/docs/hub/security-git-ssh#generating-a-new-ssh-keypair) to test my SSH authentication (base) ➜ ssh -T git@hf.co Hi ivnle, welcome to Hugging Face. ivnle is the correct account that I added my public key to, but I’m unable to clone this repository. (base) ➜ git clone hf.co:datasets/bigcode/starcoderdata data/starcoderdata-raw Cloning into 'data/starcoderdata-raw'... ivanlee@hf.co: Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the reposi…
