Skip to content

Arch Default Browser on KDE

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.

Terminal window
/usr/bin/xdg-mime: line 885: qtpaths: command not found
Terminal window
xdg-settings get default-web-browser

Confirm that qtpaths is missing from PATH while qtpaths6 is present.

Terminal window
which qtpaths
which qtpaths6

Confirm which package provides qtpaths6. Expected result: extra/qt6-base … usr/lib/qt6/bin/qtpaths6.

Terminal window
sudo pacman -Fy
pacman -F qtpaths6

Create a symlink so xdg-mime can find qtpaths on PATH.

Terminal window
sudo ln -s /usr/lib/qt6/bin/qtpaths6 /usr/local/bin/qtpaths

If the symlink already exists or needs to be replaced, use -f to overwrite.

Terminal window
sudo ln -sf /usr/lib/qt6/bin/qtpaths6 /usr/local/bin/qtpaths

Verify qtpaths is now available.

Terminal window
which qtpaths
qtpaths --version
Terminal window
xdg-settings set default-web-browser firefox.desktop
xdg-settings get default-web-browser

xdg-settings alone does not always cover every link type. Set the http, https, and html handlers directly.

Terminal window
xdg-mime default firefox.desktop x-scheme-handler/http
xdg-mime default firefox.desktop x-scheme-handler/https
xdg-mime default firefox.desktop text/html

Verify the handlers.

Terminal window
xdg-mime query default x-scheme-handler/http
xdg-mime query default x-scheme-handler/https
xdg-mime query default text/html

Open a link through xdg-open. It should launch in Firefox. No reboot or shell refresh is required.

Terminal window
xdg-open https://example.com