HTMLIFrameElement: allow property - Web APIs | MDN

Value

A string indicates the Permissions Policy specified for this <iframe> element, each policy must be separated by space.

Examples

html

<iframe
  id="el"
  src="https://example.com"
  allow="geolocation 'self' https://a.example.com https://b.example.com; fullscreen 'none'"></iframe>

js

const el = document.getElementById("el");
console.log(el.allow); // Output: "geolocation 'self' https://a.example.com https://b.example.com; fullscreen 'none'"

See Permissions Policy in <iframe> element for more available examples.

Specifications

Specification
HTML
# dom-iframe-allow

Browser compatibility

See also

Help improve MDN

Learn how to contribute

This page was last modified on by MDN contributors.