Skip to content

Team Gitee Passwordless Collaboration Guide (Windows / macOS)

Team Gitee Passwordless Collaboration Guide (Windows / macOS)

Section titled “Team Gitee Passwordless Collaboration Guide (Windows / macOS)”

After a one-time setup, team members can pull, edit, and commit code and documents directly inside their IDE (Qoder / Trae) — without ever opening the Gitee website or typing a username and password. No more logging into the web UI just to click “Upload File / New Document / Edit Online”.

The trick is to replace account passwords with SSH keys: set it up once and it works indefinitely. Unlike personal access tokens, SSH keys never expire, and you will never see the dreaded 403 / Access token is expired error again.

📌 What “passwordless” really means: your day-to-day pull / commit operations no longer require logging into the website. The initial setup still requires signing in to the Gitee website once to paste your public key (see Step 6), and you must already have been added as a repository collaborator by the project owner.

Just follow the steps in order. Every step tells you what you should expect to see — if you see something different, check the troubleshooting table in section seven.

#What to confirmHow to confirm
1You have a Gitee account and have been added as a collaborator on this projectAsk the project owner. ⚠️ This project is a private repository — without collaborator access, the clone in Step 8 will definitely fail
2git is installed on your computerRun git --version in a terminal. If it prints a version number (e.g. git version 2.4x), you are good

If item 2 reports “command not found”: on Windows, restart your IDE (Qoder or Trae) and try again (they usually bundle git). If it still fails, contact the project owner.

The project owner will give you a repository address shaped like: git@gitee.com:<org-name>/<repo-name>.git

⚠️ <org-name> and <repo-name> are placeholders — replace them with the real values the owner gives you. Do not copy them literally.

Note for international readers: Although this guide is written for Gitee, the exact same workflow works with GitHub — just replace gitee.com with github.com everywhere.

SSH is simply hanging a padlock on Gitee, while you keep the only key:

NameAnalogyWhere it livesCan it be shared?
Public keyThe padlockAttached to your Gitee account✅ Yes (it is meant to be given away)
Private keyThe keyOnly on your own computer❌ Never share it with anyone

Once configured, every Gitee operation boils down to one question: “Can the key in your hand open the lock on my door?” If yes, you are in.

Why not just use a username and password?

Gitee does not allow your login password for Git operations. The alternative is a personal access token, but tokens have an expiry date (once expired, you get 403 or Access token is expired). An SSH key has no expiry — configure once, done forever. That is why this guide recommends SSH.

Press the Win key → type powershell → press Enter.

(The built-in terminal of Qoder / Trae works equally well. All commands below can be copied and pasted directly.)

Step 2 · Check Whether SSH Is Already Installed

Section titled “Step 2 · Check Whether SSH Is Already Installed”
Terminal window
ssh -V
  • If it shows OpenSSH_for_Windows_x.x → ✅ already installed, continue to Step 3
  • If it says “‘ssh’ is not recognized…” → you need to install it: Settings → Apps → Optional Features → Add a feature → search for OpenSSH Client → Install → reopen PowerShell and run ssh -V again
Terminal window
git config --global user.name "Your Name"
git config --global user.email "the-email-you-used-to-sign-up-on-Gitee"

⚠️ The email must be the one bound to your Gitee account, otherwise your commits will not show up on Gitee as yours. Not sure which email that is? Log in to Gitee → click your avatar (top-right) → Settings → Email Management.

Step 4 · Generate Your Key Pair (Public + Private)

Section titled “Step 4 · Generate Your Key Pair (Public + Private)”
Terminal window
ssh-keygen -t ed25519 -C "the-email-you-used-to-sign-up-on-Gitee"

You will be asked a few questions. Normally, just press Enter for all of them:

PromptHow to answer
Enter file in which to save the key (...)Enter (use the default location)
Enter passphrase (empty for no passphrase)Enter (leave it empty)
Enter same passphrase againEnter
❗ If you see ... already exists. Overwrite (y/n)?A key pair already exists on this machine. Do not overwrite it — type n and press Enter, then jump straight to Step 5 (you already have a key, just use it)

⚠️ Run this in a normal PowerShell window, not one launched with “Run as administrator”. Keys generated in an administrator session are saved into the administrator account’s profile, and later cannot be found by your normal session — the symptom is Permission denied (publickey).

After generation, the keys live in the .ssh\ folder under your user directory (usually C:\Users\<you>\.ssh\, precisely $env:USERPROFILE\.ssh):

  • id_ed25519 — the private key (the key). Never share it
  • id_ed25519.pub — the public key (the padlock). This is what you copy in the next step
Terminal window
Get-Content "$env:USERPROFILE\.ssh\id_ed25519.pub" | Set-Clipboard

No output means success — the public key is now in your clipboard.

If Set-Clipboard is not available (very old system), open the file in Notepad instead, press Ctrl+A then Ctrl+C:

Terminal window
notepad "$env:USERPROFILE\.ssh\id_ed25519.pub"
  1. Open this URL in your browser: https://gitee.com/profile/sshkeys
  2. Click “Add SSH Key” (新增公钥)
  3. Title: anything you like (e.g. “My office PC”)
  4. Key: press Ctrl+V to paste what you copied in Step 5 (a trailing newline is fine)
  5. Click “OK” and confirm with your Gitee login password when prompted

Step 7 · Verify the Setup (★ the only checkpoint of the whole process)

Section titled “Step 7 · Verify the Setup (★ the only checkpoint of the whole process)”
Terminal window
ssh -T git@gitee.com

The first time, you will be asked:

The authenticity of host 'gitee.com (...)' can't be established.
Are you sure you want to continue connecting (yes/no/[fingerprint])?

→ Type yes and press Enter (this is normal — it only confirms the server’s identity once).

Seeing the following line means ✅ success:

Hi <username>! You've successfully authenticated, but GITEE.COM does not provide shell access.

Judge success by this line only — do not look at “error / exit code” hints. Gitee always appends “does not provide shell access”, which is normal, not an error.

First switch to your Desktop (so the code lands somewhere you will immediately see):

Terminal window
cd $env:USERPROFILE\Desktop
# Note: replace <org-name> and <repo-name> below with the real values from the project owner
git clone git@gitee.com:<org-name>/<repo-name>.git

A folder named after the repository will appear on your Desktop — the download is complete.

If you get Repository not found or 403: the first checkbox did not pass — you have not been added as a collaborator yet. Ask the project owner to add you, then retry.

Identical to Windows (the same Steps 1–8), with only 3 differences:

StepWindowsmacOS
Step 1 Open a terminalWin → powershellCommand + Space → type Terminal
Step 2 Check SSH(may need installing)ssh -V just works (built into macOS)
Step 5 Copy the public keyGet-Content "$env:USERPROFILE\.ssh\id_ed25519.pub" | Set-Clipboardpbcopy < ~/.ssh/id_ed25519.pub
Step 8 Switch to Desktopcd $env:USERPROFILE\Desktopcd ~/Desktop

All other commands can be copied verbatim. On macOS the keys also live under ~/.ssh/: id_ed25519 (private) and id_ed25519.pub (public).

Download → Open in IDE → Browse → Commit

Section titled “Download → Open in IDE → Browse → Commit”

This section uses Qoder as the example; Trae is nearly identical in both UI and workflow.

“Cloning” means copying the complete code from Gitee to your computer.

✅ If you already ran Step 8 in the previous section, the code is on your machine — jump straight to “Open the project in your IDE” below.

Pick either way to download:

Option A · Command line (recommended, always works) — the same command as Step 8 above:

Terminal window
cd $env:USERPROFILE\Desktop
git clone git@gitee.com:<org-name>/<repo-name>.git

macOS users: replace the first line with cd ~/Desktop, and substitute the real <org-name>/<repo-name>.

Option B · IDE GUI: on the Qoder or Trae welcome page click “Clone Repository”; or press Ctrl+Shift+P to open the command palette, type Git: Clone, paste git@gitee.com:<org-name>/<repo-name>.git, and pick a local folder.

(Menu locations vary slightly between versions; Option A always works.)

Qoder / Trae → File → Open Folder → select the <repo-name> folder you downloaded in the previous step

Use the file tree on the left; modified files are highlighted automatically.

  1. Click the “Source Control” icon in the left sidebar (shortcut Ctrl+Shift+G, Cmd+Shift+G on Mac)
  2. Type a one-line commit message in the input box
  3. Click ”✔ Commit”
  4. Click “Sync / Push” to push to Gitee

At no point will a login popup appear — your key is quietly doing the work in the background.

Tick every box and your setup is complete:

  • git --version prints a version number
  • ssh -T git@gitee.com prints Hi <username>! ...
  • The folder cloned in Step 8 contains README.md
  • After opening that folder in Qoder / Trae, the “Source Control” panel is visible on the left
  • Change one character in Qoder / Trae → commit → push, and the commit appears on the Gitee website with your avatar / name on it
  • The whole process above never asked for a password and never made you open the Gitee website (except the one-time public-key paste) — the goal of this guide is met
SymptomCauseFix
ssh: command not foundOpenSSH client not installed on WindowsGo back to Step 2 and install it
Permission denied (publickey)Public key not attached to Gitee / attached to a different account / key generated in an administrator PowerShellRe-check the public key in Step 6; if Step 4 used an administrator PowerShell, regenerate a pair in a normal PowerShell
The authenticity of host ... can't be establishedFirst connection — a normal fingerprint confirmationType yes and press Enter; happens only once
Commits on Gitee don’t show as mineWrong user.email set in Step 3Set it to the email bound to your Gitee account; new commits will be attributed correctly
Repository not found / 403Not added as a collaborator (this is a private repository)Ask the project owner to grant collaborator access
Access token is expiredYou are using HTTPS + token instead of SSHRe-clone using the git@ address from Step 8, not an https:// URL
ssh -T hangs for over 30 secondsCorporate network blocks port 22Gitee SSH only supports port 22; if blocked, fall back to “HTTPS + personal access token” and contact the project owner
Section titled “Optional: One “Foolproof” Config (Recommended)”

With this one line, any link you copy — whether it starts with https:// or git@ — will just work, so you never have to worry about link formats again:

Terminal window
git config --global url."git@gitee.com:".insteadOf "https://gitee.com/"

(Behaves identically in Windows PowerShell and the macOS terminal.)

  1. id_ed25519 (the file without .pub) is your private key — it is effectively your identity card. Never send it to anyone, never upload it to the internet, never commit it into a repository
  2. Only id_ed25519.pub (the public key) may be shared
  3. When switching computers or if you suspect a leak, delete the old public key at https://gitee.com/profile/sshkeys and generate a new pair from Step 4

After completing this section, you have mastered:

SkillKey operations
Passwordless SSH principlePublic key (padlock) on Gitee, private key (key) on your machine — never expires
Windows setupssh-keygen → Set-Clipboard → paste on the website → verify with ssh -T
macOS setupSame commands; copy the key with pbcopy, Desktop is ~/Desktop
Day-to-day IDE workflowClone → Open Folder → commit & push in the Source Control panel, fully passwordless
Foolproof configurl."git@gitee.com:".insteadOf rewrites HTTPS URLs to SSH automatically

Building a commercial IoT product?

We provide ESP32 ODM design-to-manufacturing services. From prototype to production — the team behind this tutorial can build it with you.

Talk to us →