Hi everyone, as the purpose of this topic was to announce embed changes, we’re going to close it for further comments. However, I’m going to include many of the tips that were discussed above that helped resolved many issues. Please review these items for troubleshooting before opening a new topic. Thank you!
Top troubleshooting tips
- Make sure you have SSL enabled for your website, this is required for embeds to function (i.e. When going to your site, “https://” is in the URL)
- Do not include “https://” as part of the parent value
- You cannot use wildcards as a parent value. For example,
parent=*.example.com
is not valid - Does your site allow or need “www.” in the URL? If specifying just your domain name isn’t working (e.g.
parent=example.com
) you may need to add a second parent value to specify the domain with “www.” if visitors can view your website this way as well. For example,
<iframe src="https://player.twitch.tv/?channel=twitchpresents&parent=example.com&parent=www.example.com" />
Wix websites
- Make sure to include three parent values; your site’s domain, your site’s domain with “www,” and your site’s subdomain from
filesusr.com
. Here’s an example if I was embedding the TwitchPresents channel on my websiteexample.com
:
<iframe src="https://player.twitch.tv/?channel=twitchpresents&parent=example.com&parent=www.example.com&parent=www-example-com.filesusr.com" />
- For further discussion with Wix, see: The great big "I'm using WIX/SomeWebsiteMaking Tool and I don't know how to fix my embed" thread
Squarespace websites
- Make sure SSL is enabled (Settings->Advanced->SSL and select “Secure”)
- Include your domain and the Squarespace subdomain. Here’s an example if I was embedding the TwitchPresents channel on my website
example.com
:
<iframe src="https://player.twitch.tv/?channel=twitchpresents&parent=example.com&parent=example.squarespace.com" />
Local development
- Use “localhost” or “127.0.0.1” as the parent value to use either HTTP or HTTPS in local development. Any port can be used, though this does not need to be specified anywhere (80, 3000, 8100, etc)
Embed in a local file
- Since a domain is required, embedding Twitch in a file and opening it in a browser such that the URL begins with “file://” will not succeed
Mobile development
- Will update this comment with more information
Election apps
- Will also update this comment with more information as it seems Electron apps typically use
origin: "file://"