Google Chrome: blocking Speech Synthesis API audio autoplay
Google Chrome will block audio autoplay on websites that use the Speech Synthesis API in version 71 of the browser.
Google's stance on autoplaying content in Chrome is relatively straightforward: autoplay with sound is only allowed if the Chrome user interacted with the site previously. Currently, Chrome uses a Media Engagement Index on desktop that may allow autoplay on sites even if the user did not interact with the site during the active browsing session.
The Speech Synthesis API, an API for creating text-to-speech output, is not subject to this policy. When you visit the linked test site, you will notice that Chrome will play audio on page load automatically.
If you open the console in Chrome 70, the current Stable version of the browser, you get a notification that the part of the API that allows text-to-speech output without user interaction, is deprecated.
Chrome continues to support text-to-speech, but users need to interact with content on the page first before audio can be played. If you open the linked example site in Chrome 71, you will notice that audio is not played automatically anymore.
Other browsers, Firefox and Microsoft Edge, play audio on connect to the demo site.
Why is Google making the change?
The introduction of autoplay policies blocked advertisers and shady websites from throwing autoplaying ads with sound or notifications to users.
The Speech Synthesis API could be used instead by these sites to play audio automatically, e.g. to display ads or notifications, and use sound to get the attention of the user.
Google admits that the deprecation of the functionality impacts sites that use API for legitimate purposes; the company notes, however, that the "majority of usage of this API was for abuse" and not legitimate purposes.
Google plans to add functionality to the browser's sound autoplay whitelist to allow sites to play audio automatically using the Speech Synthesis API. Users who want audio autoplay on sites can enable the functionality again by whitelisting sites.
Now You: What is your take on audio autoplay on the Web? (via Bleeping Computer)Advertisement