* docs: refresh the .github/assets copies the RayLabsHQ profile hotlinks * docs: dark copies of the README screenshots * docs: dark screenshots for the gallery, part one * docs: dark screenshots for the gallery and docs, part two * docs: dark screenshots next to the light ones The README, the homepage gallery, the docs and the use cases now show dark screenshots in dark mode. The README uses <picture> with prefers-color-scheme, like the Star History chart. The website follows its own theme toggle, which sets .dark on <html>, so each place renders both images and shows one with dark: classes. The dark set is taken from the same demo data and the same clock as the light one. The .github/assets copies of the organisation, activity and configuration screenshots are refreshed too, since the RayLabsHQ profile hotlinks them.
Gitea Mirror
Automatically mirror repositories from GitHub to your self-hosted Gitea/Forgejo instance.
Gitea Mirror keeps a self-hosted copy of your repositories. Connect GitHub (or GitLab, Gitea, Forgejo or any git host), pick a Gitea or Forgejo server, and it mirrors your repositories, organizations and starred projects there, with issues, pull requests, releases, wiki and LFS if you want them, and keeps them in sync on a schedule.
Quick start
git clone https://github.com/RayLabsHQ/gitea-mirror.git
cd gitea-mirror
docker compose -f docker-compose.alt.yml up -d
Open http://localhost:4321 and create an account; the first one becomes the admin. Then connect a source and a destination on the Configuration page. The Quickstart walks through it, including the compose file to use without cloning.
Features
- Mirror your public, private and starred repositories and whole organizations, including public organizations you are not a member of
- Sources: GitHub, GitHub Enterprise and GitHub Apps, plus GitLab, Gitea, Forgejo and plain git hosts in beta (Sources)
- Destinations: Gitea as pull mirrors, plus Forgejo, and GitHub or GitLab as push targets, in beta (Destinations)
- Issues, pull requests (as issues), labels, milestones, releases with assets, wiki and Git LFS, with filters and limits per organization and repository
- Mirror strategies to keep the source's structure, use one organization, or put everything under your user, plus a destination per organization or repository
- Scheduled syncs, discovery of new repositories, and cleanup that archives mirrors whose source is gone (Cleanup and reconcile)
- Force-push protection: a snapshot, or your approval, before a sync rewrites history
- Notifications through ntfy, Apprise, Gotify or a signed webhook
- Sign in with email and password, OIDC single sign-on, or a header from your reverse proxy (Authentication)
- A REST API with API keys, and an MCP server for AI assistants
- Live dashboard, activity log, storage overview and CSV export
- Tokens encrypted at rest with AES-256-GCM
Install
| Method | Guide |
|---|---|
| Docker Compose | Quickstart |
Plain docker run |
Deployment |
| Kubernetes with Helm | Deployment |
| Nix and NixOS | Deployment |
| Proxmox LXC | Deployment |
| Unraid | Unraid guide |
| Bare metal with Bun | Deployment |
The image is ghcr.io/raylabshq/gitea-mirror, built for amd64 and arm64. Before upgrading, see Backups and upgrades.
Documentation
- Configuration guide and environment variables
- Tokens and permissions for every source and destination
- Repositories and organizations for day to day use
- Reverse proxy and URLs
- Troubleshooting for the questions that come up most
- Use cases such as backing up GitHub, moving to Gitea, or mirroring GitLab
Community projects
Built by the community on top of the Gitea Mirror API:
- GiteaMirrorBot by MajMcCloud: a Telegram bot that spots GitHub links posted in a group and, when you confirm, adds the repository or organization to Gitea Mirror and starts the mirror. It can also post notifications back into the group. Runs as a single binary or a Docker image.
Contributing
Contributions are welcome. Read the contributing guide first; docs/DEVELOPMENT_WORKFLOW.md covers the local setup. Report security issues privately through GitHub security advisories.
License
GNU Affero General Public License v3.0 (AGPL-3.0), see LICENSE.
Star history
Support
About
Gitea Mirror is made by RayLabs, a small software company that builds apps and open source tools. See what else we make at raylabs.io.




