Contributions not showing on contribution graph after email change #187023
-
Discussion TypeQuestion Discussion ContentHi GitHub Support, I accidentally deleted my primary email address last week and added a different email instead. I then added my original email back and set it as the primary email. Details:
Could you please help rebuild my contribution graph? Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
|
Here’s what happened and how you can fix it 👇 When you removed your primary email, GitHub stopped linking your past commits to your account. Contributions only show on your profile if the commit email matches a verified email on your GitHub account. Even if you re-added the email, contributions won’t show unless all of the following are true: ✅ Step 1: Make sure the old email is verified Go to: Settings → Emails Confirm the old email is added Make sure it is verified If not, verify it from your inbox ✅ Step 2: Check the email used in your commits Run this in one of your local repositories: git config user.email If this email is different from the one verified in GitHub, your contributions won’t link. To see the email used in past commits: git log --pretty=format:"%h %ae" | head If you see an email that is NOT added to GitHub, that’s the problem. ✅ Step 3: Check for “noreply” email issue If you enabled “Keep my email addresses private”, GitHub may use something like: 12345678+username@users.noreply.github.com Make sure this noreply email is listed in your GitHub email settings. ✅ Step 4: Make sure contributions are not private Go to: Profile → Contribution settings Ensure: ✅ Step 5: Wait for GitHub to reindex Sometimes it takes: A few minutes Sometimes up to 24 hours GitHub needs time to re-link commits. 🚨 If It Still Doesn’t Work Then your old commits were made with an email that: Is different Was never verified Or contains a typo In that case, the only way to fix old commits is to rewrite Git history (advanced method). 💡 Most Common Cause 99% of the time the issue is: The commits were made with an email that is not currently verified on your GitHub account. If you want, paste the output of: git log --pretty=format:"%ae" | sort | uniq And I’ll tell you exactly what’s wrong. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks for posting in the GitHub Community, @ankitkumarsharma! 👋 We’re happy you’re here. You’re more likely to get a useful response if your question is posted in the most applicable category. The In the meantime, if your contribution graph isn’t showing what you expect (missing commits, gray squares, or changes after merging), this guide walks through how it works and the most common reasons contributions might not appear: 👉 Understanding Your Contribution Graph 🟩 It covers what counts as a contribution, private contributions, and frequent causes like branch or email mismatches. Best of luck! |
Beta Was this translation helpful? Give feedback.
Thanks for posting in the GitHub Community, @ankitkumarsharma! 👋
We’re happy you’re here. You’re more likely to get a useful response if your question is posted in the most applicable category. The
Discussionscategory is solely for conversations about the GitHub product Discussions. This question is a better fit forProfile, so I’ve gone ahead and moved it for you.In the meantime, if your contribution graph isn’t showing what you expect (missing commits, gray squares, or changes after merging), this guide walks through how it works and the most common reasons contributions might not appear:
👉 Understanding Your Contribution Graph 🟩
It covers what counts as a contribution, private contri…