google-chrome
Launch the Google Chrome web browser
TLDR
View documentation for the original command
SYNOPSIS
google-chrome [OPTIONS] [URL...]
PARAMETERS
--incognito
Opens a new incognito window, preventing browsing history, cookies, and site data from being saved.
--new-window
Forces a new browser window to open, even if an existing Chrome instance is running.
--app=<URL>
Opens the specified URL in an app mode window, without the usual browser UI elements like address bar or tabs.
--profile-directory=<NAME>
Specifies the profile to use (e.g., 'Default', 'Profile 1'). Creates it if it doesn't exist.
--user-data-dir=<PATH>
Overrides the default user data directory. Useful for portable installations or specific testing environments.
--headless
Runs Chrome in headless mode, without a visible UI. Ideal for automated testing, scraping, or server-side rendering.
--disable-gpu
Disables GPU hardware acceleration. Useful for troubleshooting rendering issues or in headless environments.
--no-sandbox
Disables the sandbox. Use with extreme caution as it significantly reduces security.
--remote-debugging-port=<PORT>
Enables remote debugging over HTTP on the specified port. Useful for programmatically controlling Chrome.
--version
Prints the Google Chrome version information to standard output and exits.
--help
Displays a limited set of command-line options and exits.
DESCRIPTION
The google-chrome command is the primary executable for launching the Google Chrome web browser on Linux systems. It allows users to open new browser windows, specific URLs, or control various aspects of the browser's behavior directly from the command line. Built on the Chromium open-source project, Google Chrome provides a fast, secure, and feature-rich browsing experience, integrating with Google services and offering extensive developer tools.
The command supports a wide array of flags to customize its launch, including opening in incognito mode, as a specific application, or managing user profiles. It's an essential tool for both everyday web browsing and advanced use cases like web development and automated testing (especially with its headless mode). When invoked without arguments, it typically opens a new browser window with the default homepage or previously open tabs. When URLs are provided, it attempts to open them in new tabs or windows.
CAVEATS
Running google-chrome directly as the root user is generally discouraged due to security implications and is often prevented by default. It requires an X server environment (unless using --headless). The browser can be resource-intensive, especially with many tabs or extensions. Many advanced flags are undocumented and primarily for internal development or testing, and their behavior may change without notice.
USING MULTIPLE PROFILES
Google Chrome supports multiple user profiles, each with its own bookmarks, history, extensions, and settings. You can launch Chrome with a specific profile using --profile-directory=<NAME>. For example, to open a profile named 'Work': google-chrome --profile-directory="Work". If the profile doesn't exist, Chrome will create it.
HEADLESS MODE FOR AUTOMATION
The --headless flag is extremely powerful for scripting and automation. It allows Chrome to run without a GUI, making it suitable for server environments or CI/CD pipelines. Combined with --remote-debugging-port, it can be controlled programmatically using tools like Puppeteer or Selenium for web scraping, testing, or PDF generation.
HISTORY
Google Chrome was first released for Microsoft Windows in September 2008. The Linux version, along with macOS, followed in December 2009, initially as a beta. The google-chrome command became the standard entry point for launching the browser on Linux, following typical naming conventions for desktop applications. Its development and usage have evolved in parallel with the browser's features, with increasing emphasis on command-line options for automation, web development, and integration into various workflows.