navigator.share() opens the device's native share sheet — the same one native apps use. It must be triggered by a tap and only works over HTTPS.

Share a link

Shares this site's URL with a title and a short message.

Share a file

Fetches a server-generated file, wraps it in a File and shares it through the OS after checking it is shareable with navigator.canShare().