Choose Mailspring as the Default Mail Client on Linux

How can I set Mailspring as the default mail client on Linux?

This article is for Linux. For Windows, see Choose Mailspring as the Default Mail Client on Windows

If you installed Mailspring on Linux using the Snapcraft (.snap) package, it’s running inside a sandbox on your machine with limited access to the filesystem and your OS. This is great, but comes with a few caveats. One of these caveats is that Mailspring can’t run the commands to make itself the default mail client.

Open the System Settings application (or similar) and find “Details” or “Default Applications”. Choose Mailspring from the mail client dropdown to make it the default client on your computer. Once you change this setting, Mailspring will open in response to mailto:// links in other applications:

This does not work. Using Kubuntu 22.04, I have tried to get Brave to open email links in Mailspring. It is set as my default Email application but Brave ignores it.

I am not using any Snap applications. I have tried every possible combination of entries on the “Protocol handlers” page in Brave. It always opens email links in Gmail web page.