# How to add a video to your email?

## 1. Create the block <a href="#h_c943d8a166" id="h_c943d8a166"></a>

Once you have finished the structure of your email, you can add **Blocks** to define the content of each part of your email. On the left, select **Video** and add it to your email:

<figure><img src="/files/CvPBOJoTIpi4X8ajL8jd" alt=""><figcaption></figcaption></figure>

## 2. Link the video <a href="#h_e294499593" id="h_e294499593"></a>

You can choose between **2 ways** to include videos in your emails.

### Add the URL link to the video <a href="#h_7352159b8e" id="h_7352159b8e"></a>

It is the safest way to broadcast videos because it works perfectly with all email clients and on all devices.

{% hint style="info" %}
The video is not in the email, your users will be redirected following the URL link in their web browser.
{% endhint %}

Click on the **Video** block to open the settings panel on the right side of the screen and there, paste the link to your video. Our system will automatically fill in the **Alternate text** field but you can change it as you want:

<figure><img src="/files/BuLga7tdcEo6UUJwz7r8" alt=""><figcaption></figcaption></figure>

You can now custom some parts such as:

* The color of the **Play button**
* The **thumbnail** image (the preview image of the video) through the **Custom Thumbnail** button
* The **alignment** and the **size** of the preview

### Embed video

The embedded video is played directly in e-mails. Recipients don't have to access another website to view it.

{% hint style="danger" %}
Embedded videos are **only supported by Apple Mail** (native iOS messaging), **Thunderbird**, and **Outlook for Mac**.
{% endhint %}

You need to change the **Video** block to the **HTML** one to custom the code of the video:

<figure><img src="/files/OOjP7I0JXe6sBKYwJeeg" alt=""><figcaption></figcaption></figure>

Once the HTML block is in place, click on **Insert elements with custom code** to open the code editor screen:

<figure><img src="/files/PQHOR14kYn4LsnKkpBhF" alt=""><figcaption></figcaption></figure>

Here, you can use the following piece of code and customize it as you please:&#x20;

```
<video class="adapt-img" controls="controls" poster="https://tlr.stripocdn.e-mail/content/guids/CABINET_0bd21bea47f1cfb916fb84d59a107495/images/92621531318217276.jpg" width="100%" height="313">

                                <source src="http://www.w3schools.com/html/mov_bbb.mp4" type="video/mp4">

                                <source src="http://www.w3schools.com/html/mov_bbb.webm" type="video/webm">

                        <!-- fallback -->

                        <a href="https://www.youtube.com/watch?v=ryqOEPk51Lg/" class="esd-frame-element esd-hover-element esdev-disable-select"><img class="adapt-img" src="https://tlr.stripocdn.e-mail/content/guids/CABINET_0bd21bea47f1cfb916fb84d59a107495/images/48461531318273724.jpg" alt="" width="100%" height="313"></a>

                       </video>Show more

```

{% hint style="info" %}
The part of the code after "**fallback**" is intended for recipients whose devices and email clients do not support this interactivity. They are redirected to YouTube, Vimeo, or any other video hosting site.
{% endhint %}

That's it! You now know everything about video in our Email Composer :sparkles:


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://doc.batch.com/guides-and-best-practices/message/email/content-and-media/how-to-add-a-video-to-your-email.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
