February 7, 2017

How to open a chromeless Chrome browser window on macOS

This is a great tip to run apps on separate windows or just for taking cool app screenshots, like this:

Screenshot of a website from a headless browser
Screenshot using a headless browser

How to open a chromless window

Open Terminal app and type:

open -n -a 'Google Chrome' --args "--app=[URL]"

Where [URL] is the desired URL. e.g:

open -n -a 'Google Chrome' --args "--app=https://www.google.com"

If you’re curious about what those flags do, -n “Open a new instance of the application even if one is already running.”, -a “Opens with the specified application” whatever that means.

Source: @DasSurma on Twitter