Things about changing Github username
First, the official GitHub doc on changing username says you can change your GitHub username at any time. It also mentions how to change and what happens after you change. But there are still some things to consider afterwards. The author of things to do after username changes has done these things many times, therefore this article lists the subsequent things to do to make the transaction as smoothly as possible.
Key points on what happens after username changes
The good news are the Web links to your existing repositories will continue to work, they will automatically redirect. However the links to your previous profile page does not.
Your old username becomes available for anyone else to claim. That also means you may can not change your username back to the old one for it being used by someone else.
You’d better update all existing remote repository URLs after changing username. Yes, they continue to work. But if the new owner of your old username creates a repository with the same name as your repository, that will override the redirect entry and your redirect will stop working.
You need to change your Github page repository <username>.github.io
with your new username. Then after a while your pages site https://<newusername>.github.io
will be available.
The rest things you need to do are updating references related to your old username like github.com/username
, username.github.io
, etc.