# "You are using an unsupported command-line flag"

> "You are using an unsupported command-line flag" means Chrome started with a risky switch. --disable-infobars only hides it headless, so we changed the engine.

Source: https://mosaicbrowser.com/blog/infobar-unsupported-flag

## The yellow "unsupported flag" bar, and how we removed it

"You are using an unsupported command-line flag" means Chrome started with a risky switch. --disable-infobars only hides it headless, so we changed the engine.

![Profile windows with no yellow band, beside a screenshot: six Mosaic profile windows arranged in a grid, each with its own name in the title bar](https://mosaicbrowser.com/covers/infobar-unsupported-flag.webp)

"You are using an unsupported command-line flag" is the yellow bar Chrome draws when it was started with one switch from a short, hard-coded list of switches that weaken security. It names the first match, adds "Stability and security will suffer", and stays until the window closes. In our browser it named a switch the product needs, on every profile, and the switch meant to hide it did nothing.

## What "you are using an unsupported command-line flag" checks

The check lives in `chrome/browser/ui/startup/bad_flags_prompt.cc`. We read it in the Chromium 156 source our engine builds from. There is an array called `kBadFlags`, and at startup Chrome walks it and stops at the first switch present on its own command line. It does not care whether a switch is unknown, misspelt or retired. Chromium takes an unknown switch in silence, which is a different problem we wrote up in [a silently ignored flag looks exactly like a working one](https://mosaicbrowser.com/blog/silently-ignored-flags).

Some of the entries in 156:

```
--no-sandbox                      --disable-web-security
--ignore-certificate-errors       --host-resolver-rules
--host-rules                      --single-process
--disable-gpu-sandbox             --disable-webrtc-encryption
--unsafely-treat-insecure-origin-as-secure
--enable-blink-features           --disable-blink-features
--use-fake-ui-for-media-stream    --log-net-log

```

Every one of them changes what the browser trusts: the sandbox, certificate checks, where a host name resolves, which origins count as secure. That is why the bar talks about security. If you started Chrome with `--no-sandbox` in a script or a desktop shortcut, the bar is right, and the fix is to drop the switch.

Two details explain behaviour people ask about. The bar names only the first match, so removing one switch can reveal the next. And Chrome adds it only to the first profile a process launches. Other profiles opened in the same Chrome come up without it.

Mosaic is a desktop app

Email yourself the link and open it on your computer.

[How it works: Fingerprints set inside the browser](https://mosaicbrowser.com/features/engine)

## Why --disable-infobars does not help

The standard advice is to add `--disable-infobars`. In a normal Chrome it changes nothing, and the reason is a few lines in `components/infobars/core/infobar_manager.cc`:

```
bool DisableInfoBars() {
  // Infobars can only be disabled when Chrome is running in headless
  // mode and in Chrome for Testing.
  return command_line->HasSwitch(switches::kDisableInfoBars)
#if !BUILDFLAG(CHROME_FOR_TESTING)
         && command_line->HasSwitch(switches::kHeadless)
#endif
      ;
}

```

Outside Chrome for Testing, `--disable-infobars` counts only when `--headless` is also there. A headed Chrome accepts the switch and drops it without a word.

What does work in stock Chrome is narrower than most answers suggest:

- **Remove the switch.** Nearly always the right answer.
- **A managed policy.** `CommandLineFlagSecurityWarningsEnabled` set to `false` hides these warnings. Chrome reads it only when it is managed (the Windows registry under `Policies`, a macOS configuration profile, or the managed policy folder on Linux), so a preference typed into a normal profile has no effect.
- **The automation path.** Chrome skips all of its startup bars when the command line has `--test-type` or `--enable-automation`. That is why a browser started by ChromeDriver with `--no-sandbox` comes up without the warning. Both are testing switches, and `--enable-automation` also sets `navigator.webdriver` to true, so it is not a cosmetic choice.

## Why our profiles showed it every time

Every Mosaic profile runs a companion, an extension with that profile's notes, logins and 2FA codes, and it talks to the app over a loopback address with its own name. To make that name always resolve to this computer, the launcher sends:

```
--host-resolver-rules=MAP 44df31b95edf6dbb.localhost 127.0.0.1

```

`--host-resolver-rules` is on the list, so every profile window opened with the bar across the top: about 40 pixels warning the operator about a switch the product requires. Our launcher had passed `--disable-infobars` from the start. It had never done anything, for the reason above, and because the switch was in the argument list it looked handled whenever someone read the launch code.

That is the same fault as the WebRTC switches that never existed. A switch the browser accepts and ignores looks exactly like one that works. This one we found by reading Chromium's source, not by measuring.

## The fix: --disable-infobars in a headed browser

[Tesseract Chrome](https://mosaicbrowser.com/features/engine) is stock Chromium source with our changes, and this one is small. It deletes the headless condition, so `DisableInfoBars()` returns true whenever `--disable-infobars` is on the command line.

What the change leaves alone matters as much. Three functions further down, `ShouldShowInfoBar()` decides what a disabled manager still shows, and it keeps every infobar that has a button. Chromium's comment calls those "semantically message boxes" that "must be shown because certain functionality depends on them". The unsupported-flag warning is created with `CreateSimpleAlertInfoBar` and has no buttons, so it goes. Anything that asks the person a question still appears. We did not want a switch that silences the browser in general, only one that removes a bar nobody using Mosaic can act on.

We checked it on the built binary: a profile launched with the same `--host-resolver-rules` rendered no band, and `--disable-infobars` was the only thing that differed. The windows on the cover are profiles on our engine, each with its own label chip by the address bar and no yellow band above the page.

![Mosaic profile windows with their names beside the address bar and no warning bar](https://mosaicbrowser.com/shots/windows-arranged.png)
*Profiles on our engine*

## A policy would have worked on stock Chrome

`CommandLineFlagSecurityWarningsEnabled` set to `false` hides the same bar without changing the engine. It has to be a managed policy, though, written into the system settings of the customer's computer, outside anything Mosaic owns. Our change touches our engine and nothing else on the machine. It also keeps a rule we follow in every change: change the engine where the behaviour lives, then verify on the browser, not on the flag list. The other differences between our build and the Chrome people run, and why they matter, are in [Chromium vs Chrome](https://mosaicbrowser.com/glossary/chromium-vs-chrome).

## Sources

1. [Chromium source: chrome/browser/ui/startup/bad_flags_prompt.cc](https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/ui/startup/bad_flags_prompt.cc), read November 2, 2026
2. [Chromium source: components/infobars/core/infobar_manager.cc](https://source.chromium.org/chromium/chromium/src/+/main:components/infobars/core/infobar_manager.cc), read November 2, 2026
3. [Chrome Enterprise policy list: CommandLineFlagSecurityWarningsEnabled](https://chromeenterprise.google/policies/#CommandLineFlagSecurityWarningsEnabled), read November 2, 2026

## Questions

### What does "You are using an unsupported command-line flag" mean?

Chrome was started with one of the switches on a fixed list in bad_flags_prompt.cc, such as --no-sandbox, --disable-web-security, --ignore-certificate-errors or --host-resolver-rules. The bar names the first one it finds. It is a warning that the switch weakens security, not a sign that Chrome failed to read it.

### Why doesn't --disable-infobars remove the bar?

In Chromium's own code the switch only works together with --headless, except in Chrome for Testing. A normal headed Chrome accepts --disable-infobars and does nothing with it.

### How do I hide the unsupported flag warning in Chrome?

Remove the switch if you can. If you cannot, the supported way is the CommandLineFlagSecurityWarningsEnabled policy set to false, which Chrome only honours as a managed policy. Automation tools avoid it because Chrome skips these startup bars when it sees --test-type or --enable-automation.

### Does Mosaic hide other Chrome infobars?

Only buttonless ones. Our change makes --disable-infobars work in a headed browser, and Chromium's own rule still shows any infobar that has a button, because those ask a question something depends on.

## Related

[An anti-detect browser with its own Chromium engine](https://mosaicbrowser.com/features/engine): Mosaic is an anti-detect browser with its own Chromium engine, Tesseract Chrome: stock Chromium source, with fingerprint values changed inside the engine.

[A silently ignored flag looks exactly like a working one](https://mosaicbrowser.com/blog/silently-ignored-flags): Chromium accepts an unknown command line switch without a word. Two of our WebRTC flags never existed, and a renamed feature did nothing for months.

[Chromium vs Chrome: same source, different browser](https://mosaicbrowser.com/glossary/chromium-vs-chrome): Chromium is the open-source browser project; Chrome is Google's build of it, with codecs, keys and components Chromium lacks. A page can tell them apart.

[Why we built our own Chromium instead of injecting JavaScript](https://mosaicbrowser.com/blog/why-we-built-our-own-chromium): Mosaic changes fingerprint values inside its own engine. Three measured differences between Chrome and plain Chromium explain why that matters.

[Machines that exist: fingerprints drawn from real hardware](https://mosaicbrowser.com/features/real-fingerprints): Mosaic draws each profile's GPU, screen, CPU, memory and fonts from one real device, so the parts of a fingerprint agree with each other and with the host.







[--blink-settings is last-wins, and that cost us a profile](https://mosaicbrowser.com/blog/blink-settings-last-wins): Chrome's --blink-settings flag sets Blink preferences like colour scheme and pointer type. A second copy deletes the first, so six profiles all came back dark.

## Mosaic, on your own computer

The browser this blog is about: its own Chromium, fingerprints from real machines and a proxy IP per profile. Free covers 3 profiles with no card, and Pro is $25 a month for any number of them.

Mosaic is a desktop app

Email yourself the link and open it on your computer.
