Reopen the current tab in any container, or open a link straight into one — with only your permanent containers in the list.
Multi-Account Containers puts every container in its tab context menu — including every throwaway container that Temporary Containers (or Temporary Containers Plus) has ever created. If you use Temporary Containers' automatic/global isolation mode, that list grows without bound and your actual permanent containers get buried.
Permanent Container Tabs adds a Reopen Tab in Container action: trivially reopen the current tab in a different container without leaving the old tab behind.
If you have Temporary Containers installed, only your permanent containers are displayed.
Works standalone, and integrates with both Temporary Containers and Temporary Containers Plus if either is installed. Neither is required.
Reopen the current tab in a container
Right-click any tab to get the Reopen Tab in Container submenu. It lists "No Container", "Temporary Container" (if Temporary Containers or Temporary Containers Plus is installed), and all of your permanent containers. Choosing a different entry closes the current tab and opens a new one at the same URL in the chosen container.
Open a link or bookmark directly in a container
Right-click any in-page link or bookmark and choose Open in New Container Tab. The same container list appears, and the link opens in the chosen container without touching your current tab.
Reach the other action via the alternate submenu
One action is always the top-level context menu item; the other sits in a nested alternate submenu just below it. You choose which is primary from the settings page.
Configure from the settings page
The options page lets you swap which of Open in New Container Tab / Reopen Tab in Container is the top-level item, and lets you disable the Temporary Containers isolation notice.
If Temporary Containers or Temporary Containers Plus is installed, Permanent Container Tabs detects it and adds a "Temporary Container" entry to every container picker, so you can still spin up a disposable container without leaving the menu.
When Temporary Containers' global isolation mode is active, it can silently redirect a tab you just opened into a fresh Temporary Container — including one you opened deliberately into a permanent container via the "Reopen" action. Permanent Container Tabs watches for this:
- On reopen, it polls briefly after the new tab is created. If Temporary Containers has intercepted it, Permanent Container Tabs opens an informational page explaining what happened (unless you've suppressed it).
- Independently of reopen, Permanent Container Tabs also watches
tabs.onUpdatedfor any tab that lands in a Temporary Container it didn't expect, and shows the same notice.
This is read-only awareness — Permanent Container Tabs never touches Temporary Containers' settings or storage, it only asks "is this cookieStoreId one of yours?" over the WebExtensions messaging API.
Permanent Container Tabs does not collect, transmit, or store anything beyond your local settings (which container action you prefer, and whether to suppress the isolation notice). No network requests, no telemetry.
Test your code well before submitting it — there's a Vitest suite covering the menu-building, reopen, and Temporary Containers detection logic; run it before opening a PR.
Using the Nix development shell (recommended in this repo):
nix develop -c npm install
nix develop -c npm run build:firefoxOr without Nix (if node and npm are already installed):
npm install
npm run build:firefoxThis writes dist/*.zip (the standard WebExtension build artifact). For a local unsigned .xpi file:
nix develop -c npm run build:firefox:xpiOther useful scripts:
npm run typecheck # tsc --noEmit
npm test # vitest runnix develop -c npm test # unit tests (Vitest, mocked browser APIs)
nix develop -c npm run test:live # real Firefox, driven over MarionetteThe live tests start a throwaway Firefox (vanilla, from nixpkgs) on a private Xvfb display, load src/ as a temporary add-on, and click real menus with xdotool. They check that Reopen Tab in Container moves the tab into the picked container, that the alternate submenu opens a copy and keeps the original, and that a link opens in the picked container. Pages are local fixtures, so no network is needed. The tests are in tests/live/; the harness is firefox-addon-live, a flake input that nix develop links in as an npm dependency.
nix develop -c npm run capture:readme # every scene
nix develop -c npm run capture:readme -- reopen link # only some scenesThis rebuilds the add-on, replays each usage scene in a live Firefox, and writes a PNG still and a GIF per scene to product-page/ (640 px wide; the settings scene is taller so the whole page shows). Scenes are in scripts/capture-readme-assets.ts.
src/background/pctRuntime.ts: top-level event wiring —menus.onShown/onHidden/onClicked,tabs.onUpdatedfor the isolation notice.src/background/menuHandler.ts: builds the tab/link/bookmark context menus and dispatches clicks to open or reopen.src/background/tabReopener.ts: implements "Reopen Tab in Container", including the TC-intercept poll loop.src/background/tcLayer.ts: detects Temporary Containers / Temporary Containers Plus, and answers "is this cookieStoreId temporary?" via cross-extension messaging.src/preferences/settings.ts: settings defaults, validation, and storage load/save.
Permanent Container Tabs only ever shows containers that tcLayer reports as not temporary — that's the entire trick behind keeping the menu permanent-only.
Stored in browser.storage.local:
prioritizeReopen(defaultfalse) — which action is the top-level menu item vs. the nested alternate.suppressIsolationInfo(defaultfalse) — never show the isolation notice page.
Two sentinel cookieStoreId values are always present alongside your real containers:
firefox-default— "No Container".temp-container— "Temporary Container", shown only when Temporary Containers or Temporary Containers Plus is detected; creates a fresh temporary container via Temporary Containers'createTabInTempContainermessage rather than a realcookieStoreId.
All code is licensed under the MIT License.



