Movatterモバイル変換


[0]ホーム

URL:


  1. Web
  2. HTTP
  3. Reference
  4. Headers
  5. Permissions-Policy
  6. autoplay

Permissions-Policy: autoplay directive

Experimental:This is anexperimental technology
Check theBrowser compatibility table carefully before using this in production.

The HTTPPermissions-Policy headerautoplay directive controls whether the current document is allowed toautoplay media requested through theHTMLMediaElement interface.

Specifically, where a defined policy blocks use of this feature and there were no user gestures, thePromisereturned byHTMLMediaElement.play() will reject withaDOMException. Theautoplay attribute on<audio> and<video> elements will be ignored.

Note:For more details on autoplay and autoplay blocking, see the articleAutoplay guide for media and Web Audio APIs.

Syntax

http
Permissions-Policy: autoplay=<allowlist>;
<allowlist>

A list of origins for which permission is granted to use the feature. SeePermissions-Policy > Syntax for more details.

Default policy

The default allowlist forautoplay isself.

Specifications

Specification
HTML
# autoplay-feature

Browser compatibility

See also

Help improve MDN

Learn how to contribute

This page was last modified on byMDN contributors.


[8]ページ先頭

©2009-2025 Movatter.jp