plyr icon indicating copy to clipboard operation
plyr copied to clipboard

Autoplay not working on iOS Safari when native fullscreen mode is enabled

Open mdomarus opened this issue 6 years ago • 3 comments

###Expected behaviour

On iOS Safari Vimeo hosted video should start automatically.

Actual behaviour

Autoplay does not work

Steps to reproduce

https://codepen.io/mdomarus/pen/MMMVam

Autoplay works when the fullscreen.iosNative is set to false.

Environment

  • Browser: Safari
  • Version: Mobile
  • Operating System: iOS
  • Version: 12.2

Console errors (if any)

Link to where the bug is happening

mdomarus avatar Jul 15 '19 18:07 mdomarus

I'm 99.9% sure this is an iOS limitation rather than an issue with Plyr. Happy to be proven otherwise though.

sampotts avatar Jul 15 '19 23:07 sampotts

Hi, also experiencing this issue with a Vimeo. Why would it be an iOS thing if it works with fullscreen.iOSNative = false?

evvvritt avatar Sep 29 '21 16:09 evvvritt

Same with HTML Video/MP4 Video, got a console error:

Unhandled Promise Rejection: NotAllowedError: The request is not allowed by the user agent or the platform in the current context, possibly because the user denied permission. (anonyme Funktion) rejectPromise play

Plyr init:

          const player = new Plyr(videoIdSelector, {
            autoplay: true,
            controls: ['play-large'],
            autopause: false,
            muted: true,
            playsinline: true,
            fullscreen: {
              enabled: false,
              iosNative: false
            }
          });

Autoplay still not working, even with fullscreen.iOSNative = false (which is the default value, so this shouldn't needed at all?).

So it seems IOS Safari is currently blocking autoplay at all? No chance?

thomasfrobieter avatar Feb 10 '22 09:02 thomasfrobieter