> ## Documentation Index
> Fetch the complete documentation index at: https://help.pipelime.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# How unsubscribe works (one-click and manual)

> The one-click headers mailbox providers act on, the optional footer link, and what an opt-out does to the lead.

export const UiPath = ({children}) => {
  const parts = String(children).split(/\s*(?:→|>)\s*/).filter(Boolean);
  return <span className="pl-path">
      {parts.map((part, index) => <span key={`${index}-${part}`}>
          {index > 0 && <span className="pl-path__sep">→</span>}
          {part}
        </span>)}
    </span>;
};

An opt-out arrives two ways: a one-click button a mailbox provider posts to on its own, and a manual confirmation the recipient submits on a page. Either one closes the lead everywhere, not just in email.

<div className="pl-availability">
  <div className="pl-availability__row">
    <div className="pl-availability__label">Where</div>
    <div className="pl-availability__value"><span className="pl-path">Settings<span className="pl-path__sep">→</span>Email Compliance</span></div>
  </div>

  <div className="pl-availability__row">
    <div className="pl-availability__label">Your role needs</div>
    <div className="pl-availability__value">Update access to Email Compliance <code>update-companies</code>. Admin have it by default.</div>
  </div>

  <div className="pl-availability__note">If you cannot find this in your sidebar, your workspace may have a custom menu configuration. Contact support and we will check it for you.</div>
</div>

The switch that turns this on (**Unsubscribe Link**, on <UiPath>Settings → Email Compliance</UiPath>) is off by default and workspace-wide: one setting covers every email account you connect, not one per account or per campaign. [Email Compliance: unsubscribe link and headers](/en/settings-team/email-compliance) walks through turning it on and writing an opt-out message; this page covers what happens once it's on.

## How it behaves

### Off by default, and warm-up mail is exempt either way

The header and the optional footer message both depend on the same gate: the workspace's **Unsubscribe Link** setting has to be on, and the message can't be warm-up traffic. Turn the setting on and warm-up mail still carries neither the header nor a footer. Only real sends do.

### The one-click header: what mailbox providers act on

When the setting is on, every real send gets a `List-Unsubscribe` header carrying two addresses: a `mailto:` address and an HTTPS URL unique to that message. It also gets a second header, `List-Unsubscribe-Post: List-Unsubscribe=One-Click`. That second header is the RFC 8058 signal: a provider that honors it (Gmail and Yahoo do) can POST straight to the URL itself, with no page and nothing for the recipient to see.

The URL carries a token: an HMAC-SHA256 hash of the message id, keyed on the app's own secret. The token is checked before the message is even looked up. A POST carrying an unrecognized or tampered token gets a plain `403 Invalid token` and nothing else happens; a good token for a message that no longer exists gets `404 Message not found`. A valid POST closes the lead (below) and answers with a plain `200 Unsubscribed successfully`: no JSON, no redirect, exactly what the endpoint's own comment says RFC 8058 requires.

Two things in the header do not follow partner branding. The `mailto:` address is a single global default (`unsubscribe@pipelime.ai`, unless an operator has configured a different one) rather than something set per workspace or per brand. The HTTPS address stays on the platform's own API domain in every workspace, because the mailbox provider is what calls it, not the recipient.

### Two more paths, no header token needed

If you write your own opt-out message on Email Compliance, the literal `{url}` you typed is swapped for the address of the confirmation page for that one message, `/unsubscribe/{messageId}`. That address carries no token, because confirming on the page stands in for the token. Whatever you wrote around it goes out as a small grey block, divided off by a line, at the bottom of the email. Leave the message empty and no footer text goes out at all; the one-click header keeps working either way.

Some mail clients turn the header's own URL into something a recipient can click, instead of posting to it invisibly. A `GET` on that exact same URL checks the token, then redirects (302) to that identical `/unsubscribe/{messageId}` page. It drops the token on the way, since confirming there takes its place. Both of those addresses are brand-aware: they use the workspace owner's partner-branding domain when one is set up, and the default app domain when there isn't.

Either path lands the recipient on the confirmation page covered in [The unsubscribe page your recipients see](/en/security/unsubscribe-page-for-recipients). Submitting it sends an email address back, and that address is compared (case-insensitively, trimmed) against the message's own recipient. A mismatch is rejected with `Email address does not match our records` instead of closing anything.

### Either way, the lead closes, not just the address

A successful one-click POST and a successful manual confirmation do exactly the same thing: `unsubscribed_at` is set to now and `stage` moves to Closed. Unsubscribing an already-unsubscribed lead is a no-op: both handlers check `unsubscribed_at` first and touch nothing if it's already set.

Closing the stage, not just flagging the address, is what makes an opt-out outlast the campaign that triggered it. A scheduled campaign email checks `unsubscribed_at` before it even generates the copy and skips the lead if it's set; a workflow's email-send block does the same, recording a skip reason instead of sending. And because it's `stage` that moved (not an email-only flag), the same close reaches LinkedIn and WhatsApp campaigns too: both already leave out any lead sitting in Closed when they pick who to message, alongside the leads who booked a meeting or converted. See [Automation toggle, closing and reopening leads](/en/leads/automation-close-and-reopen) for what else lands a lead there, and how to reopen one.

## Limits

|                                       |                                                                                                                                                                             |
| ------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Default state                         | Off: the workspace's unsubscribe setting starts disabled                                                                                                                    |
| Where it's turned on                  | <UiPath>Settings → Email Compliance</UiPath>, one switch for the whole workspace                                                                                            |
| Gated together                        | The header and the optional footer both require the setting on, and the message not being warm-up traffic                                                                   |
| Token algorithm                       | HMAC-SHA256 of the message id, keyed on the app's own secret                                                                                                                |
| One-click response                    | Plain text, `200 Unsubscribed successfully`: never a redirect                                                                                                               |
| A `GET` on the same URL               | Redirects (302) to the confirmation page, with the token dropped                                                                                                            |
| Manual match check                    | Case-insensitive, trimmed comparison to the message's own recipient address                                                                                                 |
| `mailto:` address in the header       | One global default, not set per workspace or per brand                                                                                                                      |
| Where the recipient's own link points | The workspace owner's partner-branding domain when there is one, the default app domain otherwise. The header's HTTPS address stays on the platform's API domain either way |
| Re-unsubscribing                      | A no-op: neither handler touches a lead that's already marked                                                                                                               |
| What closes                           | `unsubscribed_at` is set and `stage` moves to Closed: the same effect from either route                                                                                     |
| What stops sending because of it      | A scheduled campaign email and a workflow's email-send block both check `unsubscribed_at` first                                                                             |

## Related

<CardGroup cols={2}>
  <Card title="Email Compliance: unsubscribe link and headers" icon="sliders-horizontal" href="/en/settings-team/email-compliance">
    Turn the setting on and write an opt-out message containing `{url}`.
  </Card>

  <Card title="The unsubscribe page your recipients see" icon="mail" href="/en/security/unsubscribe-page-for-recipients">
    The confirmation form, the success state, and the mismatch error.
  </Card>

  <Card title="Acceptable use for outreach" icon="shield" href="/en/security/acceptable-use-for-outreach">
    What you may not send, and how fast an opt-out has to be honoured.
  </Card>

  <Card title="Automation toggle, closing and reopening leads" icon="circle-pause" href="/en/leads/automation-close-and-reopen">
    Pause the AI, close a lead by hand, and understand why one closed on its own.
  </Card>
</CardGroup>
