Skip to content

Capability Element - <usermedia> (former PEPC) #1392

@MinhAnhL

Description

@MinhAnhL

Specification title

Media Capture Elements

Specification or proposal URL (if available)

w3c/mediacapture-extensions#168

Explainer URL (if available)

w3c/mediacapture-extensions#168

Proposal author(s)

@MinhAnhL @tungnh28

MDN URL

No response

Caniuse.com URL

No response

Bugzilla URL

No response

Mozillians who can provide input

jan-ivar

WebKit standards-position

WebKit/standards-positions#651

Other information

Following extensive real-world validation and collaborative discussions with the web standards community (including WebKit and Mozilla), the Page-Embedded Permission Control (PEPC) initiative is evolving into a suite of specialized Capability Elements.
While the legacy PEPC focused on managing permission states, these new Capability Elements function as direct controllers for web capabilities. Specialized elements such as <geolocation>, <usermedia>, <camera>, and <microphone> move beyond simple gating to provide direct functional utility to your applications.
For requesting camera and microphone access, the element is transitioning to the modern <usermedia> element in M148, with dedicated <camera> and elements as fast follows.

While we have moved from a generic tag to capability-specific elements, the core mission of improving the web permission model remains unchanged.
Core PEPC Foundations (Carried Forward)
The following foundational benefits remain central to the new Capability Elements:

  • Reduced Friction: By establishing a "trusted signal of intent," these elements allow the developer to bypass automated interventions (like "quiet blocks" for ignored prompts) that cause traditional script-triggered requests to fail.
  • Seamless Recovery: Elements resolve the "permission hole" by providing an in-page flow to re-enable access. Users no longer need to navigate complex 15-click browser settings to reverse an accidental block.

The Shift to Capability Elements (The Upgrade)
Based on feedback and close collaboration with the web standards community, we have introduced three major upgrades:

  • Specific vs. Generic Tags: We have replaced the single <permission type="..."> element with targeted tags like <geolocation> and <usermedia> and soon also <camera> and <microphone>. This allows for tailored UI, specific attributes, and distinct security models for different device types.
  • From Gatekeeper to Data Mediator/Action Broker: Unlike PEPC, which only managed "Allow/Deny" status, Capability Elements are functional components. They handle the entire flow: getting consent, fetching the data/stream, and delivering it directly to the site—often eliminating the need for separate JavaScript API calls.
  • Stateful Capability Control: Elements are no longer just static indicators. They function as integrated UI components that streamline both the permission flow and the subsequent capability action—such as toggling a media stream (<usermedia>) or triggering an installation (<install>)—directly through the element.

Note: The linked spec and url are WIP.

See also related resources
Standard position Mozilla on <geolocation>: #1288
Standard position Mozilla on overall PEPC: #1245
Standard position WebKit on <geolocation>: WebKit/standards-positions#545
Standard position WebKit on overall PEPC: WebKit/standards-positions#270

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

Status

Needs proposed position

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions