Browser extension might be the best bet because it relies on the same browser across every system to handle securely isolating the key from the web apps. It doesn't have to ask the system to make a connection between two apps with special security rules on storage access etc.
For desktop apps it would be hard to program for how many different ways people can have their system set up compared to a bunch of similar web browsers or Android phones.