Skip to content

Instantly share code, notes, and snippets.

@inchoate
Last active December 8, 2025 12:18
Show Gist options
  • Select an option

  • Save inchoate/5736cc1257066edd8fa643ca594a4778 to your computer and use it in GitHub Desktop.

Select an option

Save inchoate/5736cc1257066edd8fa643ca594a4778 to your computer and use it in GitHub Desktop.
Open clicked URLs into a particular Google Chrome profile

Finicky Configuration Guide (v3 & v4)

Problem

When I click on links from Slack or Outlook on MacOS they open in seemingly random browser windows/profiles. This is annoying.

Solution

Open links in a particular Google Chrome profile window based on the source application or URL. Be less annoyed.

  1. In Chrome, visit chrome://version and find the desired profile name. Mine was Default. Copy that profile's directory name, like Profile 2 or Default, not the profile's vanity name you see when you click on your profile icon in the browser.
  2. Install Finicky: brew install finicky. After install it should be running and you should see the icon in the upper toolbar.
  3. From the Finicky Toolbar Item, click > Config > Create New (or edit ~/.finicky.js / ~/.finicky.ts).

Version 4 (TypeScript)

Recommended for newer installations. Create or edit ~/.finicky.ts:

import type { FinickyConfig } from "/Applications/Finicky.app/Contents/Resources/finicky.d.ts";
/**
 * Finicky Configuration
 * Version: 4.0
 */
export default {
  defaultBrowser: "Google Chrome",
  options: {
    hideIcon: false,
    checkForUpdates: true,
  },
  handlers: [
    {
      // Open specific domains in a work profile
      match: ({ url }: any) => url.host.includes("example-work-domain"),
      browser: {
        name: "Google Chrome",
        profile: "Profile 2", // Your work profile directory name
      },
    },
    {
      // Open links from specific apps in a personal profile
      match: ({ opener }: any) =>
        ["Slack", "Microsoft Outlook"].includes(opener?.name ?? ""),
      browser: {
        name: "Google Chrome",
        profile: "Default", // Your personal profile directory name
      },
    },
    {
      // Ensure Slack deep links open in the Slack app
      match: ({ url }: any) => url.protocol === "slack:",
      browser: "/Applications/Slack.app",
    },
  ],
} satisfies FinickyConfig;

Version 3 (JavaScript) Legacy configuration.

Create or edit ~/.finicky.js:

module.exports = {
  defaultBrowser: "Google Chrome",
  options: {
    hideIcon: false,
    checkForUpdate: true,
  },
  handlers: [
    {
      match: ({ opener }) =>
        ["Slack", "Microsoft Outlook"].includes(opener.name),
      browser: {
        name: "Google Chrome",
        profile: "Default",
      },
    },
    {
      match: ({ url }) => url.protocol === "slack",
      browser: "/Applications/Slack.app",
    },
  ],
};

Reload Finicky from the toolbar: > Config > Reload. Done. Enjoy.

@igormukhin
Copy link

What is an alternative for Windows?

@cawoodm
Copy link

cawoodm commented Nov 14, 2024

I made OptiBrowser for Windows 7 many years ago to solve this problem. Might be worth trying to use and/or forking for today's browsers. As it's C# (DOTNET) it should run on any platform if built appropriately.

@sanjarcode
Copy link

Thank you!

@mlz11
Copy link

mlz11 commented Jul 16, 2025

Great help, thanks @inchoate 😊

@dmackerman
Copy link

Nice, going to try this. FWIW it's not "random", it opens in whatever Profile you had focused last.

@cur1ous
Copy link

cur1ous commented Dec 6, 2025

Thanks, works like a charm! Does anyone know if it would be possible to also catch which Slack workspace the redirect is originating from? E.g. Slack Workspace A would open Chrome Profile X, Slack Workspace B would open Chrome Profile Y.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment