Command Line Options


You use following command line options when starting NW.js to change some default behaviors.

--mixed-context

Run NW.js in Mixed Context Mode instead of Separate Context Mode.

--nwapp

An alternative way to specify the path of the app. This parameter is especially useful when testing with ChromeDriver.

--data-path

Specify the data directory for your app, which contains the stored data, caches and crash dumps etc. By default the data directory is in following directories according to your platform:

  • Windows: %LOCALAPPDATA%/<name-in-manifest>/
  • Mac: ~/Library/Application Support/<name-in-manifest>/
  • Linux: ~/.config/<name-in-manifest>

Where <name-in-manifest> is the name field in manifest.

--enable-gcm

Enable the chrome.gcm API.

--enable-transparent-visuals

--disable-transparency

--disable-gpu

--force-cpu-draw

These options are related to the transparent window feature. See Transparent Window for details.

Other Chromium Options

You can also use Chromium options listed in https://github.com/nwjs/chromium.src/blob/nw13/chrome/common/chrome_switches.cc.

These options can be put into chromium-args in manifest to get NW.js running with them each time.