Jul 24, 2025 by Thibault Debatty | 901 views
https://cylab.be/blog/431/publish-your-gitlab-project-to-github
Have a GitLab repository? Want to give it more visibility? Here is how to automatically mirror your GitLab repository to Github…
Login to your github account then head to https://github.com/new to create a new public repository.
No need to add a README file or gitignore, the repo can be left completely empty…
Still on GitHub:
Settings > Developper settings (at the verry bottom) > Personnal Access Tokens > Fine-grained tokens and click Generate new token.Repository access, click Only select repositories and choose the desired repositoryPermissions, select Repository permissions > Contents > Read and writeCreate the token and don’t forget to save the token value as it will only be displayed once!
Now, on the GitLab server, open the source project, and head to Settings > Repository > Mirroring repository. Then click on Add new.
.git at the end)Password field, enter the Personal Access Token you just createdOnce the mirroring is configured, click on the spinning arrows to run the initial push.
After a few seconds your Github repo should be a mirror of your gitlab repository, and GitLab will update the Github repo each time you push new commits…
This blog post is licensed under
CC BY-SA 4.0