Custom Google Chrome settings for each computer user
October 14, 2021
Google Chrome on Linux has a number of useful options, for example:
- launching a web browser in incognito mode
- you can specify the path to the folder where the profile data and browser cache will be stored
- you can select the type of password storage
- proxy settings
Like many programs in Linux, Google Chrome supports command line options – all these settings can be specified when starting a web browser, but this is not very convenient. In addition to creating shortcuts, there is another convenient way to write settings for each computer user: all configurable flags can be specified in the ~/.config/chrome-flags.conf file, which is personal for each user.
You may have noticed information about this feature during the installation or update of Google Chrome:
==> NOTE: Custom flags should be put directly in: ~/.config/chrome-flags.conf ==> NOTE: The launcher is called: 'google-chrome-stable'
How to save settings in chrome-flags.conf file
To open (or create, if the file does not already exist) the Google Chrome personal settings file for the current user, run the command:
To set the settings for another user, specify the full path to the file in the user's home folder:
sudo gedit /home/alex/.config/chrome-flags.conf
Chrome-flags.conf file format
The settings (options) discussed below can be used both in the command line to launch a web browser (the launcher is named “google-chrome-stable”, you can also specify these settings in the ~/.config/chrome-flags.conf file.
You can use the following formats:
- each setting on a separate line
- all settings are in one line, the settings are separated by spaces
Google Chrome options and settings on Linux
Specifies the directory that user data (your "profile") is kept in. Defaults to $HOME/.config/google-chrome. Separate instances of Google Chrome must use separate user data directories; repeated invocations of google-chrome will reuse an existing process for a given user data directory.
Runs URL in "app mode": with no browser toolbars.
Open in incognito mode.
If PATH or URL is given, open it in a new window.
Specify the HTTP/SOCKS4/SOCKS5 proxy server to use for requests. This overrides any environment variables or settings picked via the options dialog. An individual proxy server is specified using the format: [SCHEME://]HOST[:PORT]
Where <proxy-scheme> is the protocol of the proxy server, and is one of:
If the SCHEME is omitted, it defaults to "http". Also note that "socks" is equivalent to "socks5".
Use the HTTP proxy "foopy:99" to load all URLs: --proxy-server="foopy:99"
Use the SOCKS v5 proxy "foobar:1080" to load all URLs: --proxy-server="socks://foobar:1080"
Use the SOCKS v4 proxy "foobar:1080" to load all URLs: --proxy-server="socks4://foobar:1080"
Use the SOCKS v5 proxy "foobar:66" to load all URLs: --proxy-server="socks5://foobar:66"
It is also possible to specify a separate proxy server for different URL types, by prefixing the proxy server specifier with a URL specifier. Example: Load https://* URLs using the HTTP proxy "proxy1:80". And load http://* URLs using the SOCKS v4 proxy "baz:1080": --proxy-server="https=proxy1:80;http=socks4://baz:1080"
Disables the proxy server. Overrides any environment variables or settings picked via the options dialog.
Autodetect proxy configuration. Overrides any environment variables or settings picked via the options dialog.
Specify proxy autoconfiguration URL. Overrides any environment variables or settings picked via the options dialog.
Setthepasswordstore to use. The default is to automatically detect based on the desktop environment. basic selects the built in, unencrypted password store. gnome selects Gnome keyring. kwallet selects (KDE) KWallet. (Note that KWallet may not work reliably outside KDE.)
Show version information.
Google Chrome obeys the following environment variables:
Shorthand for specifying all of http_proxy, https_proxy, ftp_proxy
http_proxy, https_proxy, ftp_proxy
The proxy servers used for HTTP, HTTPS, and FTP.Note: because Gnome/KDE proxy settings may propagate into these variables in some terminals, this variable is ignored (in preference for actual system proxy settings) when running under Gnome or KDE.Use the command-line flags to set these when you want to force their values.
Specify proxy autoconfiguration.Defined and empty autodetects; otherwise, it should be an autoconfig URL.But see above note about Gnome/KDE.
SOCKS proxy server (defaults to SOCKS v4, also set SOCKS_VERSION=5 to use SOCKS v5).
Comma separated list of hosts or patterns to bypass proxying.
All Google Chrome command line options
Google Chrome has hundreds of undocumented command line flags that are added and removed at the whim of the developers. The above are relatively stable flags documented.
If you are interested in a complete list of Chrome and Chromium flags, then you can refer to these lists:
Another way to view the complete list of flags is to find the chrome_switches.cc file (path ./chrome/common/chrome_switches.cc) in the source code of the web browser.
- Chromium will no longer sync passwords - what should Linux users do? (100%)
- How to change the language of Google Chrome and Chromium on Linux (100%)
- How to use Kali Linux to check web-sites (50%)
- How to run small Python code in Bash (50%)
- How to completely uninstall a package along with dependencies on Arch Linux (as well as BlackArch and Manjaro) (50%)
- How to find and remove non-UTF-8 characters from a text file (RANDOM - 50%)