[BUG] Claude Code Web creates PR URL with hardcoded 'main' instead of default branch

Resolved 💬 3 comments Opened Jan 11, 2026 by dimalib Closed Feb 28, 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?

Claude Code Web correctly works with code from the default branch (dev),
but when creating a PR, it generates URL with hardcoded 'main':

compare/main...claude/branch-name

Should be:
compare/dev...claude/branch-name

Repository default branch is set to 'dev'.

What Should Happen?

PR URL should use the repository's default branch instead of hardcoded 'main'.

If default branch is 'dev', URL should be:
compare/dev...claude/branch-name

Error Messages/Logs

Steps to Reproduce

  1. Have a GitHub repository with default branch set to 'dev' (not 'main')
  2. Open Claude Desktop App for Windows
  3. Start a new remote/cloud session with this repository
  4. Make any code changes
  5. Let Claude create a PR (or click "Create PR" button)
  6. Observe the generated PR URL: compare/main...claude/branch-name
  7. Expected: compare/dev...claude/branch-name (should use default branch)

Claude Model

Opus

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

Claude Desktop App for Windows (latest version, cannot run --version in GUI app)

Platform

Anthropic API

Operating System

Windows

Terminal/Shell

Other

Additional Information

Platform: Claude Desktop App for Windows (not CLI, not web)
Using cloud/remote sessions feature within the desktop app.

Screenshot attached showing repository default branch is set to 'dev'.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗