[BUG] Claude Code web session loses GitHub push access mid-project

Status Closed — not planned
Reported on v2.1.132
Maintainer reply None cached
Activity 11 comments · opened May 7, 2026 · closed Jun 8, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Environment: Claude Code web (claude.ai/code)

Issue: Git push stopped working mid-project with persistent 403 errors,
despite the GitHub OAuth app being authorized. Previous commits on the
same branch pushed successfully.

Error:
remote: Permission to raymondckearney/Curio.git denied to raymondckearney.
fatal: unable to access 'http://127.0.0.1:<port>/git/raymondckearney/Curio/':
The requested URL returned error: 403

Steps taken without success:

  • Disconnected and reconnected GitHub in claude.ai settings multiple times
  • Closed and reopened the session (proxy port changed, 403 persisted)
  • Attempted push via GitHub MCP tool (same 403)

Root cause observed: GitHub settings show Claude is authorized as an OAuth
app but "has not been installed on any accounts" — the GitHub App
installation appears to be missing or was never completed, so only read
access works, not write/push.

Request: The Claude Code web onboarding flow should ensure the GitHub App
is fully installed (not just OAuth-authorized) before allowing git
operations, or provide a clear "Install GitHub App" button when push
access fails.

What Should Happen?

GitHub push should work reliably throughout a session. If the GitHub App installation is missing or the push token expires, Claude Code should detect this automatically and prompt the user to reinstall/reauthorize — not silently fail with a 403.

Error Messages/Logs

Steps to Reproduce

  1. Connect GitHub via claude.ai settings (OAuth only — no GitHub App install prompt)
  2. Open a Claude Code web session on an existing repository
  3. Have Claude make and commit changes
  4. Claude attempts git push → 403 error
  5. Disconnecting/reconnecting GitHub in settings does not fix it
  6. Closing and reopening the session does not fix it
  7. Push remains broken for the remainder of the session

Claude Model

Sonnet (default)

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

Claude Code 2.1.132.

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Other

Additional Information

_No response_

View original on GitHub ↗

11 Comments

github-actions[bot] · 3 months ago

Found 3 possible duplicate issues:

  1. https://github.com/anthropics/claude-code/issues/48769
  2. https://github.com/anthropics/claude-code/issues/56988
  3. https://github.com/anthropics/claude-code/issues/33952

This issue will be automatically closed as a duplicate in 3 days.

  • If your issue is a duplicate, please close it and 👍 the existing issue instead
  • To prevent auto-closure, add a comment or 👎 this comment

🤖 Generated with Claude Code

AlteonSolutions · 3 months ago

Having same issue...

Body:

Git push has stopped working for my repository (alteonsolutions/mapper-scripts) with a persistent 403 error. This was working correctly for weeks and stopped without any changes on my end.

Error:

remote: Permission to AlteonSolutions/mapper-scripts.git denied to AlteonSolutions.
fatal: unable to access 'http://127.0.0.1:[PORT]/git/AlteonSolutions/mapper-scripts/': The requested URL returned error: 403
What I've tried:

Disconnected and reconnected GitHub in Claude Code settings
Opened multiple new sessions
Tried pushing to both main and feature branches
Git fetch (read) works fine — only writes fail
Additional observations:

The local proxy URL (http://local_proxy@127.0.0.1:PORT) changes port on each session, confirming sessions are refreshing
My GitHub settings show a "Claude Code" fine-grained PAT and SSH key, both marked "Never used" — suggesting the actual auth was always handled by an internal platform credential, not these tokens
That internal credential appears to have expired or been revoked on Anthropic's side
Environment:

Claude Code web (claude.ai/code)
Repo: github.com/alteonsolutions/mapper-scripts (personal account, not org-restricted)
Platform: Linux

RalphMolenaar · 3 months ago

Same issue over here....

tunaon · 3 months ago

Same issue over here.... Too...

vikash-reddy · 3 months ago

FYI. I encountered the same issue with claude code web.
I worked around the problem by specifying my github pat in a prompt.
Then the claude code web session successfully executed git remote add github https://github.com/redacted/redacted.git && git push https://github_pat_redacted@github.com/redacted/redacted.git redacted 2>&1

AlteonSolutions · 3 months ago

Refreshing and providing a new PAT worked for me as well...not sure why it stopped working suddenly but it's working now.

________________________________
From: Vikash Gunreddy @.*>
Sent: Saturday, 09 May 2026 18:13:24
To: anthropics/claude-code
@.*>
Cc: Duke Bonaventura @.>; Comment @.>
Subject: Re: [anthropics/claude-code] [BUG] Claude Code web session loses GitHub push access mid-project (Issue #57009)

[https://avatars.githubusercontent.com/u/7351845?s=20&v=4]vikash-reddy left a comment (anthropics/claude-code#57009)<https://github.com/anthropics/claude-code/issues/57009#issuecomment-4413817722>

FYI. I encountered the same issue with claude code web.
I worked around the problem by specifying my github pat in a prompt.
Then the claude code web session successfully executed git remote add github https://github.com/redacted/redacted.git && git push @.***/redacted/redacted.git redacted 2>&1


Reply to this email directly, view it on GitHub<https://github.com/anthropics/claude-code/issues/57009#issuecomment-4413817722>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/B6DTIHC3WJZIERRFSD6DGH34Z6UQJAVCNFSM6AAAAACYUUNJBCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHM2DIMJTHAYTONZSGI>.
Triage notifications on the go with GitHub Mobile for iOS<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675> or Android<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you commented.Message ID: @.***>

jfoo1984 · 3 months ago

same, I generated a PAT and was able to have a claude code session use that. I also found that even a new CCW session has the same problem, and I need to give it a PAT.

github-actions[bot] · 2 months ago

Closing for now — inactive for too long. Please open a new issue if this is still relevant.

18272100491bb-gif · 1 month ago

➕1

pazuuuuu · 1 month ago

同じ症状が出てるので早期解決を求めます。

basilevs · 1 month ago

Just happened to me https://claude.ai/code/session_01X4UoEvFk839WJtSDR9jv9Y

Workaround:

  • Open https://github.com/settings/installations. If "Claude" appears only under Authorized OAuth Apps and not under Installed GitHub Apps, that's the bug.
  • Install it from https://github.com/apps/claude and grant access to basilevs/rat_tracer (or all repos).
  • Start a new session afterwards. Credentials are minted when the container starts, so this session will keep its read-only token even after you fix the installation.

Note that Claude will try to extort team subscription after a couple redirects. Ignore that, close the tab, retry push. No need to restart session!