Parse the URL before grouping
For each tab, separate the URL into its hostname and path. For example:
https://shop.example.com/cart→ hostname:shop.example.com; path:/carthttps://shop.example.com/orders/42→ hostname:shop.example.com; path:/orders/42https://docs.example.com/guide→ hostname:docs.example.com; path:/guidehttps://news.other-site.test/story→ hostname:news.other-site.test; path:/story
The first two tabs have different paths but the same hostname. They are consistent members of one exact-host group. The documentation tab uses a different hostname, even though example.com appears in both addresses. Treating every shared base domain as one group would broaden the rule beyond exact-host grouping.
A hostname is also different from a page title or visible brand. Two services can use similar names, and one service can operate several subdomains. Make the hostname the decision boundary before moving or grouping any tab.
Worked Firefox example
Consider this illustrative set in one normal Firefox window:
https://shop.example.com/products— ordinary tabhttps://shop.example.com/checkout— ordinary tabhttps://docs.example.com/api— ordinary tabhttps://news.example.net/story— ordinary tab- A pinned tab containing a frequently used homepage
The two shop.example.com tabs qualify for the same exact-host group. Their paths differ, but that difference is irrelevant to hostname membership. Keep both pages open and treat the group as a container for related pages from that host.
The docs.example.com tab stays outside that group. It may belong to a separate group if there are other documentation tabs, but one related base domain is not enough reason to combine it with shop.example.com. The news tab is unrelated and remains outside the example groups.
Keep the pinned tab separate. Pinning represents a different browser state, so it should not be pulled into an ordinary hostname group merely because its URL resembles another tab. The expected result is one proposed group for the two shop pages, with the documentation, news, and pinned tabs unchanged.
Apply the decision in Firefox
- Select one normal window and list its open tabs. Do not mix tabs from another window while deciding membership.
- Read each URL’s hostname. Ignore paths when comparing exact-host membership.
- Put tabs with identical hostnames into one candidate set.
- Put subdomains into separate sets unless you have deliberately chosen a broader rule.
shop.example.comanddocs.example.comare separate exact-host sets. - Leave one-tab sites ungrouped when grouping them would add no useful context.
- Exclude pinned tabs from ordinary grouping.
- Review the proposed membership before applying any Firefox grouping command or extension action.
Repeat the process independently in each selected normal window. If the same hostname appears in two windows, that does not by itself justify moving tabs between them. Window boundaries matter: make a group inside each window rather than treating all matching URLs as one cross-window set.
Check edge cases before changing tabs
A URL such as https://shop.example.com/?ref=email still has hostname shop.example.com; its query string does not create a new group. Conversely, https://www.example.com and https://example.com are different hostnames for an exact-host rule, even when they serve similar content.
Do not assume that Firefox exposes an automatic “group by domain” command, or that an extension supports every Firefox window type. Available controls and extension compatibility can vary by browser version. Verify the current Firefox behavior first, then compare its proposed membership with your hostname list.
The useful stopping point is clear: group the two identical-host shop tabs, keep the different subdomain and unrelated news page out, and leave the pinned tab untouched. Broaden the rule only when you intentionally want related subdomains together; shared branding alone is not sufficient.
How To Create Tab Groups In Firefox