GitHub lets you change your username once every 7 days, and the process takes about two minutes
Go to your GitHub account settings, find the "Account" section in the left sidebar, scroll to the "Change username" field, type your new name, and click "Change username" to confirm. GitHub will update your profile when ready, but it takes a few minutes for the change to show everywhere — in your repositories, your profile page, and links other people have shared.
The old username becomes available for someone else to claim after you change it. If you want to keep it reserved, you can create a new account with that name and keep it inactive, though GitHub does not offer a formal username hold. Your repositories, followers, and contribution history all move with you to the new username.
Key Takeaways
- You can change your GitHub username once every 7 days from the Account settings page.
- All your repositories, followers, and contribution history move with your new username automatically.
- Old links to your profile and repositories will redirect to your new username for at least 301 days.
- If you use GitHub Pages, your site URL will change from username.github.io to your new username, and you must update the repository name to match.
- Anyone who has cloned your repositories locally will need to update their remote URL to point to your new username.
Where to find the username change setting
Log into GitHub and click your profile photo in the top right corner. Select "Settings" from the dropdown menu. On the left sidebar, click "Account" — this is different from "Profile settings," which only lets you change your display name and bio.
Scroll down until you see the "Change username" section. It will show your current username and a text field below it. This section only appears if you have not changed your username in the past 7 days; if you changed it recently, you will see a message telling you when you can change it again.
What happens to your old username and links
When you change your username, GitHub keeps your old username reserved for 301 days. During that time, anyone who visits your old profile URL or clicks an old link will be automatically redirected to your new profile. After 301 days, your old username becomes available for someone else to claim.
This redirect applies to your profile page and all your repositories. If someone has bookmarked your profile or a link to one of your repositories, those links will still work. However, if you want to be cautious, you can notify collaborators and anyone who might have cloned your repositories that your username has changed.
Updating GitHub Pages if you have a website
If you use GitHub Pages to host a website, your site URL will change when you change your username. A site that was at oldusername.github.io will move to newusername.github.io. You must also rename the repository itself to match your new username for the site to work.
To rename the repository, go to the repository settings, find the "Repository name" field at the top, change it to newusername.github.io, and save. GitHub will update the site URL within a few minutes. If you have a custom domain pointing to your GitHub Pages site, you do not need to change anything — the custom domain will continue to work.
Telling people who cloned your repositories
If other people have cloned your repositories to their computers, their local copies will still point to your old username. They will not be able to push changes or pull updates until they update the remote URL.
They can fix this by running git remote set-url origin https://github.com/newusername/repositoryname.git in their local repository folder, replacing "newusername" and "repositoryname" with the actual values. If you maintain a popular open-source project, you might want to post a notice in your README or in a GitHub discussion so people know to update their remotes.
What does not change when you update your username
Your user ID number stays the same, so GitHub can track your contributions and keep your account history intact. Your repositories, stars, followers, and all your contribution history move with you. Any SSH keys or personal access tokens you have created will continue to work without any changes on your part.
Organizations you belong to will still have you as a member. Pull requests and issues you opened will still show your name. The only things that change are the URL paths and the name people see when they visit your profile or repositories.
Frequently Asked Questions
Can I change my username more than once?
Yes, but only once every 7 days. If you change your username and want to change it again, you will need to wait a full week before the option becomes available. There is no limit to how many times you can change it over time, as long as you wait the 7 days between changes.
What if someone takes my old username after the 301-day redirect period?
After 301 days, your old username becomes available for anyone to claim. If someone else takes it, old links to your profile will no longer redirect — they will show that person's profile instead. To prevent this, you can create a new account with your old username and keep it inactive, though this uses up a GitHub account slot.
Do I need to update my SSH keys or tokens when I change my username?
No. SSH keys and personal access tokens are tied to your user ID, not your username, so they continue to work exactly as before. However, if you have any scripts or tools that reference your username in URLs, you will need to update those manually.
Will my GitHub contributions graph stay the same?
Yes. Your contribution history, including your contribution graph and all the green squares on your profile, move with you to your new username. Nothing is lost or reset when you change your username.
Can I change my username if I have an organization?
Yes. Changing your personal username does not affect any organizations you own or belong to. The organization name stays the same, and you remain a member with the same permissions you had before.