Iterable's View in Browser link lets email recipients open a hosted web view of an email campaign they've received. The hosted page can differ from the email in the recipient's inbox. To archive an exact copy at send time, use the Stored Messages add-on.
# In this article
# How View in Browser works
View in Browser is a dynamic link that you can insert into an email template. The link itself is constructed when Iterable renders the message for sending. The View in Browser page is rendered on demand at the time of view or click.
When a recipient clicks View in Browser, Iterable looks up the original
send record. The record identifies the recipient, references the template,
and contains any transactionalData Iterable kept from the send.
When Iterable generates the hosted page, it uses the send-time template revision when available. It looks up user profile values, data feed responses, and Catalog records when the page opens, rather than reusing their values from the original send. That's why the page can differ from the original email, even when the recipient opens it directly from their inbox. To archive an exact copy at send time, use the Stored Messages add-on.
# View in Browser for proofs
When you click a View in Browser link in a proof email, it opens a web view that can differ from the proof in your inbox.
When you send a proof As random users, or from the Preview page with another user's data loaded, the proof email uses that user's data. However, the View in Browser page still uses the proof recipient's user profile. If the recipient's profile has different values, or is missing fields that the template references, the View in Browser page can differ from the proof email or show blank merge tags.
Keep in mind that because proofs don't include send-time transactionalData,
merge tags that rely on it resolve to blank on the View in Browser page—the
same way they do in the proof email itself if no dataFields were provided.
After editing a template, send a new proof and share its link. Don't rely on a previously shared link to reflect edits.
To test View in Browser with a fully populated send record, send a live message to an example user with your template and populated data fields.
# Adding a View in Browser link to an email
To add a View in Browser link to an email:
- Insert the
{{viewInBrowserUrl}}Handlebars merge tag into the template. See Handlebars Reference: viewInBrowserUrl. - In the drag-and-drop email editor, use the View in Browser special link.
# View in Browser URL composition
# Link host
A View in Browser link uses the same host as your other rewritten email links, such as click and open tracking links:
- If your project has a verified custom link tracking domain
that matches the From address, the link uses that domain (such as
links.example.com). - Otherwise, the link uses Iterable's default link tracking domain for your
project's region:
links.iterable.comfor USDC-based projects, orlinks.eu.iterable.comfor EDC-based projects. For more information, read Iterable's European Data Center (EDC).
# Link protocol
A View in Browser link uses HTTPS when your tracking domain is configured for HTTPS. To enable HTTPS on a custom tracking domain, read Configuring HTTPS for Link Tracking Domains.
# Link path
After the host, the rest of the URL contains encrypted, opaque routing data that identifies the project, message, and recipient. Use the link as Iterable generates it—don't construct or edit View in Browser URLs by hand.
# Troubleshooting View in Browser page rendering
When something goes wrong, what you see depends on how the request is made. The subsections below group common causes by what Iterable typically returns or by symptom.
# HTTP 400 Bad Request — Invalid messageId/templateId
If Iterable can't read the message ID, it returns HTTP 400 Bad Request with
Invalid messageId/templateId. If the send record is unavailable but Iterable
can read the message ID, it can try to render the latest template without the
original send-time data.
# Failed to render message
If Iterable can't re-render the email, check for template or snippet errors, an unavailable data feed, or an empty Catalog collection.
# HTTP 410 Gone — This link has been deactivated
Iterable returns HTTP 410 Gone with a plain-text body similar to:
This link has been deactivated.
Typical cause: Iterable has deactivated the links for the campaign that sent this message. Link deactivation disables all tracking links for a campaign, including the View in Browser link. If you believe this is in error, contact Iterable Support.
# Page loads, but content is missing, incomplete, or different from the send
Check the delivered email first. If the content is correct there, a difference on the View in Browser page doesn't mean the original send was affected.
When Iterable re-renders a message, the page may not match what the recipient saw in the inbox if a data source changed or is missing.
The following content and data sources are subject to content drift:
User profile fields — Drift occurs if profile fields (for example, name, locale, or custom fields) changed after the send.
Template revision fallback — If the original send record is missing and Iterable can read the message ID, it can try the latest revision.
Data feeds — Drift occurs if the data feed's URL, response body, or upstream data changed after the send. If the data source is unavailable, the page may fail to render.
Catalog collections and items — Drift occurs if a record was edited after the send. If the data source is unavailable, the page may fail to render.
-
transactionalData(trigger and API send context) — Drift occurs if thetransactionalDatawas dropped because it exceeded the send-event storage limit. See Understanding Triggered Message Data.NOTE
Iterable treats missing
transactionalDataas an empty object, so affected merge tags resolve to blank rather than producing an error. The same applies if the recipient's user profile has been deleted—profile merge tags also resolve to blank. The link came from a proof, not a live send. See View in Browser for proofs for how proofs are handled.
# Common questions
# Why does the View in Browser page show different content than the inbox copy?
When Iterable re-renders the email, it uses current profile, data feed, and Catalog values. The page can also differ if the original send-time data is unavailable. See Page loads, but content is missing, incomplete, or different from the send.
To preserve an immutable copy of what Iterable sent, use Stored Messages.
# Do clicks on the View in Browser link count as link clicks for the campaign?
No. Clicking the View in Browser link does not generate a click event. Clicks on links inside the rendered page are tracked normally, the same way as clicks from the inbox version.
# What does GET /api/email/viewInBrowser return?
The View in Browser API endpoint, GET /api/email/viewInBrowser,
returns the HTML for the same view as the link in the email. Provide the
recipient's email or userId and the messageId from the send. If Iterable
re-renders the email, the HTML can differ from what arrived in the inbox. For
an exact copy, use the Stored Messages add-on.