Hi everyone,
I’m trying to embed YouTube videos in our email marketing campaigns (EDMs) to boost viewership. I was using iframes to achieve this, but I’m encountering an error message: “Error: Iframe tags are not allowed. Please remove it as it makes your email unsafe to send.”
Can anyone shed light on why Hubspot doesn’t allow iframes in EDMs? Additionally, are there any potential security risks associated with sending emails containing YouTube iframes?
If iframes are not a possibility, I’m open to alternative methods for embedding YouTube videos in our–provided that the YouTube video can be played within the EDM itself, not necessarily needing to redirect to Youtube to play the video. Any suggestions would be greatly appreciated!
Regards,
MSantos24
Hi @MSantos24,
There are a few concerns with iFrames in marketing emails:
- Security Risks: iFrames can be exploited to run malicious code, track user activity, or inject harmful content. Email clients aim to protect users from potential security threats, so they block iframes to minimize these risks.
- Compatibility Issues: Many email clients (like Gmail, Outlook, etc.) don’t support iframes. If you include them, the email may not render correctly for many recipients, leading to a poor user experience.
- Deliverability Concerns: Emails containing iframes are more likely to be flagged as spam by email servers, which can significantly impact your email deliverability and open rates.
If you want to include video in your email, you can follow these steps: Add videos to HubSpot content
Alternatively, consider creating a gif from a few seconds of your video, overlay a play button and hyperlink the gif to get people to click on it and play the video in their browser.
Best regards!
Embedding iframes in email marketing campaigns is generally not supported due to security concerns and compatibility issues. Here are some insights and alternative methods to achieve your goal of embedding YouTube videos in emails:
Why Hubspot (and other email clients) Don’t Allow iframes:
- Security Risks:
- iframes can be used to inject malicious content or exploit vulnerabilities in email clients, posing a security risk to recipients.
- Compatibility Issues:
- Many email clients (like Gmail, Outlook) strip out iframes to ensure the email content is safe and consistent across various platforms and devices.
Alternative Methods:
1. Use a Thumbnail Image with a Link:
- Create a screenshot or thumbnail of your YouTube video.
- Add a play button overlay to the image to make it look like a video player.
- Link the image to the YouTube video URL.
- When recipients click the image, they will be redirected to YouTube to watch the video.
2. Use an Animated GIF:
- Create a short GIF from the video to give the illusion of a playable video.
- Link the GIF to the YouTube video.
3. Use a Video Thumbnail Service:
- Some services (e.g., Playable) create youtube video thumbnails that appear as playable videos in the email, but they actually redirect to the video hosted on the service’s platform.
Benefits of These Alternatives:
- Increased Security: No security risks associated with iframes.
- Better Compatibility: Ensures the email renders correctly across different email clients.
- Clear Call to Action: The play button on the thumbnail or GIF makes it clear to recipients that clicking the image will play the video.
Using these alternatives will help you safely and effectively include YouTube videos in your email marketing campaigns without encountering security issues or rendering problems.
Trying to embed a YouTube video directly in an email is like trying to fit a square peg in a round hole. The tech just isn’t there. Email clients are built to protect users, not to deliver a seamless video experience. That’s why they block iframes and anything that smells risky.
But honestly, this is a blessing in disguise. The goal isn’t to play a video in the email. The goal is to get people to click, watch, and take action. A strong thumbnail with a play button is a proven pattern. It’s familiar, it’s safe, and it works.