Home

Awesome

BrowseRouter

In Windows, launch a different browser depending on the url.

Survey

Browse Router has gotten more attention than expected. You can help determine what happens next by filling out this survey.

Support

If you like BrowseRouter, let me know in a discussion. I work a full time job. BrowseRouter is just a hobby. You can help support continued development by "buying me a coffee."

<a href="https://www.buymeacoffee.com/slater1" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 60px !important;width: 217px !important;" ></a>

Why?

BrowseRouter becomes your default "browser". When you click a link, it decides which real browser to launch. If you have multiple browsers installed, this is very useful. Example use cases:

Security

BrowseRouter does no tracking and makes no network connections of its own whatsoever.

Your system administrator could know which pages you are visiting by auditing process start logs e.g. BrowseRouter.exe http://some-naughty-site.com. They would have the same information for any browser.

Credit

This is a fork of BrowseSelector. That version is no longer mantained. This version carries on the vision, fixing bugs and adding new features.

Setting Up

  1. Clone and extract to a folder somewhere on your PC.
  2. Open config.ini and customize paths to your browsers and domain patterns (see below).
  3. As administrator, Run BrowseRouter.exe --register from this folder to register the tool in Windows as a web browser.
  4. (Optional) Open default browser chooser: from the Start Menu, search for "default browser" or "default apps". Select BrowseRouter as the default browser.
  1. If you skipped step 4, the first time you click on a link after registring BrowseRouter as a browser, you will be presented with the Open With dialog.

Tested on:

Usage

    BrowseRouter.exe --register
        Register as a web browser.

    BrowseRouter.exe --unregister
        Unregister as a web browser.
        Once you have registered the app as a browser, you should use visit "Set Default Browser" in Windows to set this app as the default browser.

    BrowseRouter.exe http://example.org/
        Launch a URL

Notifications

By default, BrowseRouter will show a desktop notification when it opens a link. You can disable this in config.ini.

Notification

Config

Config is a poor man's INI file:

[notify]
# Show a desktop notification when opening a link. Defaults to true
enabled = true

[log]
# Write log entries to a file. Defaults to false
enabled = true
# Defaults to C:\Users\<user>\AppData\Local\BrowseRouter\yyyy-MM-dd.log
#file = "C:\Users\<user>\Desktop\BrowseRouter.log"

# Default browser is first in list
# Use `{url}` to specify UWP app browser details
[browsers]
ff = C:\Program Files\Mozilla Firefox\firefox.exe
# Open in a new window
#chrome = "C:\Program Files (x86)\Google\Chrome\Application\chrome.exe" --new-window
chrome = C:\Program Files (x86)\Google\Chrome\Application\chrome.exe
edge = C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe

# Url preferences.
# - Only * is treated as a special character (wildcard).
# - Only domains are matched. Don't include protocols e.g. "https://" or paths e.g. "/some/path?query=value"
# - Beware that subdomains don't match automatically, e.g. "youtube.com = chrome" would not launch Chrome for "www.youtube.com"
#   For that reason, you'll often want a leading "*." e.g. "*.youtube.com". 
#   Note: Don't use "*youtube.com" as that would also match e.g. "notyoutube.com".
[urls]
*.google.com = chrome
*.youtube.com = chrome
*.visualstudio.com = edge
*.mozilla.org = ff

# Source preferences.
# Only * is treated as a special character (wildcard).
# Matches on window title of application used to open link.
# Applied regardless of any url preference match.
[sources]
* - Notepad = ff
Slack | Test = chrome
# Default case. Added automatically
# * = whatever

Browsers

Sources

Urls

There are two ways to specify an Url. You can use simple wildcards or full regular expressions.

Simple wildcards:

microsoft.com = ie
*.microsoft.com = ie

Full regular expressions:

  /sites\.google\.com/a/myproject.live\.com/ = chrome

Sources

Wildcards and full regular expressions may also be used to match source window titles.

Logs

Logs are stored by default in %localappdata%/BrowseRouter/. For example, if you user name is joe, then the logs will be in C:\Users\joe\AppData\Local\BrowseRouter\.

You can change the directory in the [log] section of config.ini.

You can enable disable or log files by setting enabled = true or false in the [log] section of config.ini. If enabled is missing or doesn't equal true, logs will not be written.

Log entries are also written to the console and can be seen if e.g. if launched from Command Prompt, PowerShell, or Windows Terminal.

Log entries are also written to Application logs in Windows Event Viewer.