thunderbird / thunderbird/thunderbird-android

Allow selecting Preferred Browser for Sign-In Workflows (add/new email setup)

Open
#8,237 0 comments 0 reactions 1 assignee View on GitHub

@shamim-emon is already working on this.

Since May 9, 2026.

type: enhancement
Dominant language
Kotlin
Stars
14k
Forks
2.8k
Avg merge
3d 3h
Merged PRs (30d)
57

Description

Checklist
  • I have used the search function to see if someone else has already submitted the same feature request.
  • I will describe the problem with as much detail as possible.
  • This issue only contains a request for one single feature, not multiple (related) features.
App version

8.0b1

Problem you are trying to solve

I am unable to proceed past the initial account setup screen due to incompatibility with my default browser, Firefox, which is configured with strict security settings that block essential sign-in functionalities.

This prevents me from adding an email account, thereby affecting the core functionality of the app.

It would also solve issues other people have with the email setup, but improperly describe as issues with OAuth etc.

Suggested solution

Introduce a feature within the email setup workflow to allow users to select their preferred browser for sign-in processes.

This could either be a temporary override for the default browser setting or a more permanent browser choice saved within the app's preferences for all web-based interactions. Settings are however inaccessible during the initial setup.

Screenshots / Drawings / Technical details

The issue arises because the sign-in process redirects to a web page, which does not load properly in Firefox due to the security settings I employ (e.g., script blocking), and can't really turn off.

Allowing the user to select an alternative browser like Brave, where such restrictions can easily be temporarily lifted, would solve this issue. No specific UI changes are needed beyond a simple browser selection option in the settings or during the sign-in process.

I've asked ChatGPT (gpt-4o) if a solution is viable, and it seems possible:
If the goal is to allow users to specifically choose a browser that isn't the default system browser for certain actions, like signing into Thunderbird, an implicit intent isn't quite sufficient. You would need to implement a more targeted approach, possibly using an explicit intent that directly invokes the chosen browser app.

For implementing explicit intents to target a specific browser, you will need to know the package name of the browser app the user has chosen to handle the login process. Here's a general approach on how to do this:

  1. Allow the user to select the browser: You could provide a settings option in Thunderbird where users can select their preferred browser from a list of installed browsers.

  2. Store the selected browser’s package name: Once the user selects a browser, store the package name of that browser.

  3. Use an explicit intent to target the selected browser:

val url = Uri.parse("https://login.example.com")
val intent = Intent(Intent.ACTION_VIEW, url).apply {
    setPackage(selectedBrowserPackageName)  // Use the stored package name
}
if (intent.resolveActivity(packageManager) != null) {
    startActivity(intent)
} else {
    // Handle the case where the selected browser is not available
    Toast.makeText(context, "Selected browser is not installed.", Toast.LENGTH_SHORT).show()
}

This code snippet explicitly targets the browser app chosen by the user. The setPackage method is used to direct the intent to the specific app identified by selectedBrowserPackageName, which is the package name of the browser saved from the user's selection.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.