[FEATURE] Support self-hosted Gitea (and generic Git hosts) for cloud sessions
Preflight Checklist
- [x] I have searched existing requests and this feature hasn't been requested yet
- [x] This is a single feature request (not multiple features)
Problem Statement
Cloud sessions (Claude Code on the web / "Cloud" in the Desktop app) can only clone from and push to GitHub. Self-hosted GitHub Enterprise Server is supported, but only on Team and Enterprise plans. Repositories on a self-hosted Gitea instance cannot be used at all.
My code and CI live on a self-hosted Gitea server. To use cloud sessions I would have to move or mirror my repositories to GitHub, which I don't want to do.
Proposed Solution
Allow connecting a self-hosted Gitea instance (and ideally any Git server reachable over HTTPS/SSH) as a repository source for cloud sessions:
- Configure the instance URL and an access token (Gitea personal access token) in Claude Code settings on claude.ai
- Cloud sessions clone from and push branches back to that remote
- Optionally: create pull requests via the Gitea API (Gitea's API is largely modeled on GitHub's)
Even basic support (clone + push branch, no PR creation) would solve the problem.
Alternative Solutions
CCR_FORCE_BUNDLE=1: uploads the local repo to the cloud session, but the session cannot push results back to the Gitea remote. Changes have to be teleported locally and pushed manually.- Gitea push mirror to a private GitHub repo: Gitea's push mirror force-pushes and overwrites the GitHub side, so branches created by Claude on GitHub get deleted on the next sync unless they are pulled back into Gitea first. Gitea has no built-in two-way mirroring, so this requires a custom sync job.
Both workarounds are fragile and add manual steps.
Priority
High - Significant impact on productivity
Feature Category
Other
Use Case Example
- I work on a project hosted on my self-hosted Gitea; CI runs on Gitea Actions.
- I start a cloud session from the Desktop app and select the Gitea repository.
- Claude clones it, implements the change, and pushes a branch to Gitea.
- Gitea Actions runs CI on that branch; I review and merge in Gitea.
- I can close my laptop while the session runs, same as with GitHub today.
Additional Context
Related requests for GitLab (including self-hosted): #12346, #38062. This request covers Gitea, which is widely used for self-hosting (also by Forgejo/Codeberg users).
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗