Where to find the username setting
Your GitHub username lives in your account settings, not in your profile. Go to github.com and click your profile picture in the top right corner. A dropdown menu appears — select Settings. On the left sidebar, click Account. You will see a field labeled Username with your current name displayed.
This is the only place GitHub lets you change your username. You cannot change it from your profile page, your repository settings, or anywhere else in the interface. If you do not see the Account option in the sidebar, make sure you are logged in to your own account, not viewing someone else's profile.
Key Takeaways
- Your username setting is in Settings > Account on the left sidebar, not on your profile page.
- GitHub lets you change your username once every seven days, and old URLs redirect automatically for 301 days.
- Changing your username does not break existing repositories, but any links you have shared to your profile or repositories will stop working after 301 days.
- If you have two-factor authentication turned on, GitHub will ask you to confirm the change with your authentication method before saving it.
Entering your new username
Click in the Username field and delete your current name. Type the new username you want. GitHub shows you when ready whether that name is available — if the field turns red with an error message, someone else has already taken it. If it turns green, the name is yours to claim.
GitHub usernames can contain letters, numbers, and hyphens, but cannot start or end with a hyphen. They are case-insensitive, meaning GitHub treats JohnSmith and johnsmith as the same account. You cannot use spaces or special characters like periods or underscores.
Confirming the change
Once you have entered a name that is available, scroll down and click the Change username button. If you have two-factor authentication enabled on your account, GitHub will ask you to confirm using your authenticator app, text message, or security key — whichever method you set up. Enter that code and click Verify.
GitHub then saves the change when ready. Your new username is live within seconds. You will see a confirmation message on the screen, and your profile picture in the top right corner will now show your new username when you hover over it.
What happens to your old username and links
GitHub automatically redirects your old username to your new one for 301 days. This means if someone visits your old profile URL — like github.com/oldusername — they will be sent to github.com/newusername without seeing an error. After 301 days, the old URL stops working and shows a 404 page.
Any repositories you own keep working under your new username. If you have shared links to your repositories with others — in a resume, a portfolio, or a job process — those links will break after the 301-day window closes. If you need those links to stay permanent, you should update them yourself before the redirect expires, or consider using a custom domain instead.
The seven-day waiting period
GitHub limits you to one username change every seven days. If you change your username and then decide you made a mistake, you have to wait a full week before you can change it again. This rule exists to prevent people from rapidly cycling through usernames to confuse others or claim names temporarily.
If you are unsure about a new username, test it by searching for it on GitHub first to see if it looks right in search results. You can also ask a friend to visit your profile under the new name to make sure the URL and display look the way you want before the seven-day clock starts.
Updating your work after changing your username
Your repositories themselves do not break when you change your username, but any place you have hardcoded your old username needs updating. If you have a README file that links to your profile, or a website that points to your GitHub repositories, update those links to use your new username. The old links will work for 301 days, but after that they will be dead.
If you work with other people who have cloned your repositories, they do not need to do anything. Their local copies will still push and pull from your repositories under your new username. However, if they have bookmarked your profile or saved links to your repositories, those bookmarks will stop working after 301 days.
Frequently Asked Questions
Can I change my username back to what it was before?
Yes, but only after waiting seven days. If you change from alice to bob, you must wait seven days before you can change to alice again. During those seven days, alice is locked to you and nobody else can claim it.
What if the username I want is taken?
The field will show red and say the name is unavailable. You cannot reserve a username or request that someone else release it. Choose a different name, or wait to see if the person using it abandons their account (GitHub does not delete inactive accounts, so this is unlikely).
Do I need to update my Git remote URL after changing my username?
No. Your repositories will work with the old remote URL for 301 days because GitHub redirects the old username to the new one. After 301 days, the old URL will stop working and you will need to update it with git remote set-url origin pointing to your new username.
Will my followers or stars transfer to my new username?
Yes. Your followers, starred repositories, and all your contribution history stay attached to your account. Changing your username does not reset anything — it only changes the text that appears in the URL and on your profile.
What if I have two-factor authentication and lose access to my authenticator?
You will not be able to confirm the username change until you regain access to your second factor. If you have lost your authenticator app, use a backup code (which GitHub gave you when you set up two-factor authentication) or contact GitHub Support to verify your identity another way.