22

As of version 66 of Google Chrome onwards it will no longer automatically start playback of audio and video files when the playback volume is not muted.

This change was made to prevent autoplay on ad videos and other annoying web page elements. However, this has negative consequences for a number of perfectly valid applications of the autoplay feature, for instance in signage applications.

The new default behaviour of not auto playing a video with sound can be overridden at the startup of the Google Chrome browser with the command line options

--autoplay-policy=no-user-gesture-required

or

--no-user-gesture-required

The new default autoplay behaviour is also present in the Chrome browser on ChromeOS (currently in the beta channel). For Kiosk-apps running on ChromeOS there are no command line options, only configuration using the Manifest.json file.

Currently there is no option in the documentation of the Manifest.json format that allows changing the autoplay policy.

Is there any way to change the new Chrome default autoplay policy in Kiosk apps to allow autoplay of videos in an app on ChromeOS?

Bob Groeneveld
  • 903
  • 1
  • 9
  • 19
  • Thanks for the question. I could not explain better. Is there a way to add flags to the url you want to run in autostart kiosk mode in chromeOS apps? – Luis Gar May 06 '18 at 13:21
  • You can do [this](https://stackoverflow.com/a/38475044) to change Chrome startup flags on ChromeOS. – dw1 Feb 24 '19 at 20:56

3 Answers3

16

It turns out that the end user will have to enable automatic video playback manually, by:

  1. upon startup pressing Ctrl+Alt+S
  2. logging in
  3. opening a Chrome browser and typing: chrome://flags/#autoplay-policy
  4. changing the "Autoplay policy" from "Default" to "No user gesture is required"
  5. pressing "relaunch"
  6. rebooting the device

From now on autoplay works again in webview components used in your app.

See this comment thread about this topic by Google.

Pascal Lindelauf
  • 4,782
  • 4
  • 40
  • 55
  • 1
    It is not the answer I had hoped for, but it seems the Chromium/Chrome developers leave us no other option currently... – Bob Groeneveld May 07 '18 at 21:10
  • 2
    For those with managed ChromeOS devices: with the Google device management tools it is possible to set the autoplay-policy flag remotely – Bob Groeneveld May 07 '18 at 21:12
  • 1
    @BobGroeneveld where exactly is this setting in google device management? I'm having difficulty finding where to set device policies for the org. – ScottN May 14 '18 at 19:17
  • @ScottN As discussed in the same [comment thread](https://plus.google.com/+SladeColling/posts/2ux6eVbjoWB?cfem=1) mentioned in my post, there is actually no way to set this if you have a single-app kiosk license. It only seems possible when you have a full remote management license with which you can configure user policies. – Pascal Lindelauf May 16 '18 at 08:13
  • Is it possible to implement user gesture such as "Do you want to allow this website to auto-play sound?", so that it would be consistent with desktop notifications and other opt-in features? – Jón Trausti Arason May 23 '18 at 11:50
  • 9
    The flag seems to have been removed as of recent versions of Chrome (looking at 76) ... anyone have the latest way to achieve this (or know if there is one -- lets hope)? cc @BobGroeneveld – B Robster Aug 19 '19 at 14:07
  • 2
    Looks like `--autoplay-policy=no-user-gesture-required` may still be a command line option even though it's not in the flags UI – B Robster Aug 19 '19 at 14:10
12

This function is often useful on kiosks, where you want to autoplay sound from one specified site. In that case, you can just to to:

  1. Settings
  2. Advanced
  3. Privacy and Security
  4. Site Settings
  5. Sound

And enable autoplay for particular website. It should override its default behaviour and play the sound immediately after displaying site.

Grzegorz Maj
  • 166
  • 1
  • 4
5

For a kiosk, I added this site to chrome://settings/content/sound

file:///*

This allowed videos with autoplay to have sound for local files.

theobject
  • 51
  • 1
  • 1