Skip to main content
Segments are used to group and manage your Contacts. Segments are not visible to your Contacts, but are used for your own internal Contact organization.

Send emails to your Segment

Segments were designed to be used in conjunction with Broadcasts. You can send a Broadcast to an Segment from the Resend dashboard or from the Broadcast API.

From Resend’s no-code editor

You can send emails to your Segment by creating a new Broadcast and selecting the Segment you want to send it to. Send emails to your Segment You can include the Unsubscribe Footer in your Broadcasts, which will be automatically replaced with the correct link for each Contact.

From the Broadcast API

You can also use our Broadcast API to create and send a Broadcast to your Segment.
import { Resend } from 'resend';

const resend = new Resend('re_xxxxxxxxx');

const { data, error } = await resend.broadcasts.create({
  segmentId: '78261eea-8f8b-4381-83c6-79fa7120f1cf',
  from: 'Acme <onboarding@resend.dev>',
  subject: 'hello world',
  html: 'Hi {{{FIRST_NAME|there}}}, you can unsubscribe here: {{{RESEND_UNSUBSCRIBE_URL}}}',
});
Resend generates a unique link for each recipient and each Broadcast. You can use {{{RESEND_UNSUBSCRIBE_URL}}} as the link target. Unsubscribe Link

Automatic Unsubscribes

When you send emails to your Segment, Resend will automatically handle the unsubscribe flow for you. Automatic Unsubscribes If a Contact unsubscribes from your emails, they will be presented with a preference page.
  • If you don’t have any Topics configured, the Contact will be unsubscribed from all emails from your account.
  • If you have Topics configured, the Contact will be presented with a preference page where they can subscribe or unsubscribe from specific types of emails (all public Topics will be shown).
Learn more about managing your unsubscribe list or customizing your unsubscribe page.
Whenever possible, you should add a Topic to your Broadcast, as this will allow your Contacts to unsubscribe from specific types of emails (instead of unsubscribing from all emails from your account).

Export your data

Admins can download your data in CSV format for the following resources:
  • Emails
  • Broadcasts
  • Contacts
  • Segments
  • Domains
  • Logs
  • API keys
Currently, exports are limited to admin users of your team.
To start, apply filters to your data and click on the “Export” button. Confirm your filters before exporting your data. If your exported data includes 1,000 items or less, the export will download immediately. For larger exports, you’ll receive an email with a link to download your data. All admins on your team can securely access the export for 7 days. Unavailable exports are marked as “Expired.”
All exports your team creates are listed in the Exports page under Settings > Team > Exports. Select any export to view its details page. All members of your team can view your exports, but only admins can download the data.