Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Where can I set CLI flags for Google Chrome on Unity?

share|improve this question
Do you mean how to set command line options for Chrome? –  N.N. Nov 13 '11 at 9:33

4 Answers 4

up vote 2 down vote accepted

Look in /opt/google/chrome/google-chrome.desktop or /usr/share/applications/google-chrome.desktop for the following line:

Exec=/opt/google/chrome/google-chrome %U

Add the flag you need in there, save it, then run Chrome again and pin it to your launcher, that should do the trick.

share|improve this answer
...just until the next upgrade overwrites it :( –  törzsmókus Apr 28 '13 at 10:48
I’m still looking for a permanent solution to this. –  törzsmókus Apr 28 '13 at 10:51

I'm running Xubuntu and I was trying to figure this one out as well. I tried the solution to edit the .desktop file. I haven't updated, but I have the same concern as you (will it get overwritten). I tried a different option where I added an alias to my .bashrc file.

alias chromium-browser="/usr/bin/chromium-browser [FLAGS]"
share|improve this answer

First, open up a terminal. Then type in `google-chrome-(release-type) -(flag) Replace (release-type) with the release of google chrome you are using (stable,unstable,ect.) and (flag) with the flag that you want to run Google Chrome with.

To have the flags run when you click on the Google Chrome Unity icon in the launcher, first install Unity Launcher Editor. Open up a terminal window and type sudo apt-get install bzr. When it is has finished installing, type bzr branch lp:unity-launcher-editor. Next, launch Unity Launcher Editor by typing ~/unity-launcher-editor/unitylaunchereditor/main.py. Now, click on the Google Chrome icon, and add the flag you want to run in the Command box.

share|improve this answer
I want the flag to be used every time I open Google Chrome from launcher. –  Ragnis Nov 12 '11 at 23:10
Isn't there just a .desktop file somewhere that I can edit? –  Ragnis Nov 13 '11 at 10:41
I am not currently aware of a .desktop file you can edit. I would suggest you use Unity Launcher Editor as explained above to add CLI flags to the Google Chrome Launcher icon. –  Aaron Hill Nov 13 '11 at 12:53
some problem with the project, answer need to be updated –  Vaibhav Mishra Nov 5 '12 at 12:23
  1. Edit /usr/share/applications/google-chrome.desktop
  2. Add the desired flags to the Exec line
  3. Run sudo chattr +a /usr/share/applications/google-chrome.desktop to prevent your change from being overwritten on update.
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.