On Arch with KDE Plasma, apps that use the system default browser may open Chromium or Chrome instead of Firefox, and xdg-settings fails with 'qtpaths: command not found'. The cause is that qt6-base ships qtpaths6 but xdg-mime expects a command named qtpaths on PATH. The fix is a symlink plus setting the default explicitly.
Typical error
/usr/bin/xdg-mime: line 885: qtpaths: command not foundCheck the current default browser
xdg-settings get default-web-browserCheck whether qtpaths exists
Confirm that qtpaths is missing from PATH while qtpaths6 is present.
which qtpaths
which qtpaths6Confirm which package provides qtpaths6. Expected result: extra/qt6-base ... usr/lib/qt6/bin/qtpaths6.
sudo pacman -Fy
pacman -F qtpaths6Symlink qtpaths6 as qtpaths
Create a symlink so xdg-mime can find qtpaths on PATH.
sudo ln -s /usr/lib/qt6/bin/qtpaths6 /usr/local/bin/qtpathsIf the symlink already exists or needs to be replaced, use -f to overwrite.
sudo ln -sf /usr/lib/qt6/bin/qtpaths6 /usr/local/bin/qtpathsVerify qtpaths is now available.
which qtpaths
qtpaths --versionSet Firefox as default
xdg-settings set default-web-browser firefox.desktop
xdg-settings get default-web-browserSet MIME handlers explicitly
xdg-settings alone does not always cover every link type. Set the http, https, and html handlers directly.
xdg-mime default firefox.desktop x-scheme-handler/http
xdg-mime default firefox.desktop x-scheme-handler/https
xdg-mime default firefox.desktop text/htmlVerify the handlers.
xdg-mime query default x-scheme-handler/http
xdg-mime query default x-scheme-handler/https
xdg-mime query default text/htmlTest
Open a link through xdg-open. It should launch in Firefox. No reboot or shell refresh is required.
xdg-open https://example.com