macOS: Disable Video Autoplay in Safari

1 minute read
| Quick Tip

If you use Safari, you might be regularly annoyed by the tendency of certain sites to automatically play their videos when you vist the page. I know it bothers me, and yes, I’m looking at you, CNN. Thanks to the capable sleuthing of Mac Geek Gab listener Scott Barman, we can show you how to turn off video autoplay in Safari. This method works in macOS Sierra and OS X El Capitan, and probably other versions of OS X.

TMO reenactment of children cheering because they were able to disable video autoplay

You can also be this happy after you learn to disable video autoplay in Safari (Image Credit: StartupStockPhotos

Disable Video Autoplay in Safari

To disable video autoplay, you need to quit Safari completely. That means clicking Safari from the top left of the menu bar, and then Quit. Once that’s done, launch Terminal from Applications -> Utilities. In Terminal, type the following commands:

defaults write WebKitMediaPlaybackAllowsInline -bool false
defaults write -bool false

If you’re running the WebKit Technology Preview, you’ll also need to run these commands in Terminal:

defaults write WebKitMediaPlaybackAllowsInline -bool false
defaults write -bool false

That’s it. Start up Safari once again, and enjoy a life free of video autoplay.

16 Comments Add a comment

  1. Lee Dronick

    It works! At least on a favorite website, and I am sure that it is universal.

    This should be a Safari Extension

  2. GraphicMac

    Wow. This might actually make me reading again. Haven’t been there in over a year because of their stupid auto-play videos.

    • ikomrad

      I tested this…and it works!

      Well, at least today it works, until they find a way around it. I’m ok with advertisements as long as they don’t distract me from the content that I came for. If its inline with the content I’m reading ( i.e an ad inserted in-between paragraphs ) or animated or plays sounds that break my concentration from what I’m reading, then it’s a deal breaker. Silent, static ads that are outside of the “content zone” are ok with me.

  3. Jeff Butts

    vpndev: Not that I’m aware of LOL

    GraphicMac: As long as you keep reading TMO, go for it. I read Macworld on an almost daily basis, to be honest.

  4. faxus

    You can also use the Debug menu for those who have enabled it
    Defaults write IncludeInternalDebugMenu 1
    (Or SafariTechnologyPreview)
    Then Media Flags > Disallow Inline Video


  5. Lee Dronick

    Faxus, thanks for the Debug menu tip

    Seeing as this story has evolved into a Safari wish list, can we:

    1. Hide the fact that Safari is in Private mode? Some websites won’t let you in unless they can dump a ton of permanent cookies on you.

    2. Block popup nags to sign up for newsletters?

  6. Brutno

    Well, does not work for me, with the new benefit of not being able to even stop the video using its own controls. I assume to reverse this I change the “false” flags to “true” ?
    (Using 10.9.5)

  7. ikomrad

    This is a great article. I wish that there was a way to vote this article “up” to make it easier for others to find.

  8. davidqmoser

    BUT! i now want to REVERT the terminal command because it’s kind of a pain in other places… so… PLEASE… what is the code to reverse the info above? thank you!

      • davidqmoser

        Whoa, thank you for the instant response. I’ll try it. I’m the kind of user that has no business trying anything in Terminal, it’s a frightening space for the layperson.


Add a Comment

Log in to comment (TMO, Twitter, Facebook) or Register for a TMO Account