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

# Expiration, passwords & deep links

> Expire links by date or clicks, password-protect them, and route mobile and desktop to different destinations.

Beyond the destination and channel, each link can carry extra rules. Configure these from the
collapsible sections when you [create a campaign](/link-tracking/create-links), or by editing a
link later.

## Link expiration

Expire a link automatically by **date**, by **click count**, or both. Once a link is expired,
visitors are sent to a custom URL you choose, or to TrackRev's branded *"This link has expired"*
page.

<Steps>
  <Step title="Expand + Add expiration">
    In the campaign form, open the **+ Add expiration** section.
  </Step>

  <Step title="Set your limits">
    * **Expires on** — a date and time (`expires_at`).
    * **Max clicks** — expire after N clicks (blank = unlimited).
    * **Expired redirect URL** (optional) — where expired traffic goes. Blank shows the default
      expired page.
  </Step>
</Steps>

Expired links display an **Expired** badge on the Links page; links close to their date show
*"Expires {date}"* (amber within 7 days), and click-capped links show *"Max N clicks"*.

<Note>
  The two limits are independent — whichever is reached first expires the link. Expiring a link
  never deletes its click history; only the redirect stops.
</Note>

## Password protection

Gate a sensitive link behind a password. Visitors see a *"This link is password-protected"* page
and must enter the password before the redirect proceeds.

<Steps>
  <Step title="Expand + Add password protection">
    Open the **+ Add password protection** section in the campaign form.
  </Step>

  <Step title="Set a password">
    Enter the password. It's hashed (SHA-256) at save and never stored in plain text.
  </Step>
</Steps>

Protected links show a purple **Protected** lock badge on the Links page. After a visitor enters
the correct password, TrackRev sets a short-lived cookie so they aren't prompted again for **24
hours**.

## Device targeting

Send mobile and desktop visitors to different destinations from the same link — for example,
mobile to your App Store listing and desktop to the web app.

<Steps>
  <Step title="Expand + Add device targeting">
    Open the **+ Add device targeting** section.
  </Step>

  <Step title="Set per-device destinations">
    * **Mobile destination** (`url_mobile`)
    * **Desktop destination** (`url_desktop`)

    TrackRev picks the destination by the visitor's OS and device at redirect time, falling back
    to the main destination URL when no override matches.
  </Step>
</Steps>

<Tip>
  For true native-app deep links (opening an installed iOS/Android app), configure your app's
  association files (Apple App Site Association / `assetlinks.json`) and app identifiers under
  **Configuration → Domains**. TrackRev serves those files from your custom domain so links can
  open your app directly.
</Tip>

## A note on link cloaking

Branded short links naturally mask the destination — visitors see `go.yourbrand.com/spring`,
not the long underlying URL, because the branded host serves a clean short path that TrackRev
resolves server-side. There's no separate "cloaking" toggle; the branded short link *is* the
clean, masked URL.
