---
title: "Include a link to the online version of a message"
slug: "include-a-link-to-the-online-version-of-a-message"
abstract: "How to add a link so that recipients can view a message in a browser."
---
# Include a link to the online version of a message

You can add a link to the online version of a newsletter or email so that recipients can view the content in a browser or share the link.

To add a link in an email to the online version:

1. Open the `\sitecore modules\Web\EXM\layouts\Blocks\PreviewBlock.cshtml` file.
2. Add a link using the syntax shown in the following example:

    ```xml
    <a href="/?sc_itemid=@Sitecore.Context.Item.ID&sc_lang=@Sitecore.Context.Language.Name&@GlobalSettings.OnlineVersionQueryStringKey=1">
        View online version
    </a>
    ```

    > [!note]
    > If you update the `PreviewBlock.cshtml` file in this way, the link will be added in all emails. This is because all the templates share this file.

The online version of an email message:

- Is created automatically when the message is created.
- Is personalized – all the tokens in the message are replaced with the relevant values.
- Does not contain a link to the online version. EXM recognizes an online copy automatically and does not render controls that are not relevant.

    ![The online version of an email message.](https://doc.sitecore.com/api/markdown-image/xp/en/developers/exm/103/email-experience-manager/images/OpenInBrowser.png)