Error embedding youtube video on ios 18 and above. For example, when I embed this link, nothing is displayed:
I still run previous IOS versions normally, only ios 18 and above are blocked
Looks like we are getting this as well using the player plyr.io. Of course works just fine on Android ![]()
Here is a discussion over at Vidstack (original successor of Plyr) - Youtube Error 153 on Capacitor · vidstack/player · Discussion #1720 · GitHub that points to the possible issue with the Referral header.
Here are the requirements - YouTube API Services - Required Minimum Functionality | Google for Developers
I’ve been trying different things but haven’t found a solution. Just came across this open issue on the Capacitor repo - [Bug]: Ios Youtube embed player issue - Blocked a frame with origin "ionic://localhost" from accessing a frame with origin "https://www.youtube.com". Protocols must match. · Issue #8205 · ionic-team/capacitor · GitHub.
Using a proxy mentioned here might be a workaround.
Yeah, YouTube policy change. Here’s the doc others are pointing to.
I can’t say I blame them for expecting a proper referrer and referrer policy. Capacitor (and a bunch of other frameworks) will have their work cut out for them figuring this one out. In the meantime for us devs, it looks like proxying our YouTube iframes through a web server is the only solution. If anyone finds a way to hack IOS into working before a Capacitor update, let me know.
