Usually with browser settings like this, any changes you make will be discarded the next time Selenium launches a new browser instance.
Do you use a special Firefox profile to run selenium tests? If so, in this Firefox profile, set this option the way you want, and then close the browser. This should properly save it for later use. You will need to tell Selenium to use this profile, although this is done by SetCapabilities when starting a driver session.
source share