What You Are Building

TDS routes incoming traffic by conditions that simple 301/302 redirects cannot express. Rules run on a Cloudflare Worker attached to a site's acceptor domain and are evaluated on every request.

Rules come in two families — Smart Shield for filtering on request signals, SmartLink for routing on URL parameters. The next section breaks down which one to pick.

Smart Shield vs SmartLink

The two rule families are not different products — they are two ways of expressing the same rule. The split is about what triggers the match.

Smart Shield

Filter & defend

Matches on every request using signals Cloudflare attaches to the request itself — country, device, OS, browser, bot detection.

Use it when:

  • You need to block or whitewash bots before they reach your offer.
  • You want to restrict a campaign to specific countries or devices.
  • You want mobile and desktop visitors to land on different prelanders.

Presets S1–S5: Bot Shield, Geo Filter, Mobile Redirect, Desktop Redirect, Geo + Mobile.

SmartLink

Route by source

Matches only when the URL carries tracking parameters — utm_source, utm_campaign, fbclid, gclid, or any param you nominate.

Use it when:

  • You need different prelanders for Facebook (fbclid) and Google (gclid) traffic.
  • You want to split traffic by utm_campaign or sub-id.
  • You want to A/B-test variants depending on the traffic source.

Presets L1–L3: UTM Split, Facebook Traffic, Google Traffic.

Both rule types live on the same site and are evaluated in priority order — Smart Shield rules typically run first (they catch unwanted traffic regardless of URL), then SmartLink rules sort the rest by source.

What a Rule Can Match and Do

  • Conditions: path, country, device, bot detection, UTM source, UTM campaign, or referrer.
  • Actions: redirect (301/302), block, pass through, or MAB redirect.
  • Build mode: start from a preset, or build manually with full control.

TDS or a Plain Redirect?

Use a redirect for unconditional moves: domain parking, path moves, vanity URLs, maintenance mode.

Use TDS when the destination depends on the request: a slug, a country, a device, a UTM tag, or a traffic split.

Before You Start

  • A connected Cloudflare integration with the target domain synced into 301.st.
  • A site whose acceptor domain is the host that will receive traffic.
  • The reflink or destination URL you want matched traffic to land on.

Create Your First Rule

Example: send https://go.example.com/vavada to a partner reflink while everything else passes through.

  1. Open the site, go to the Streams tab, and click New rule.
  2. Pick a preset or choose Manual for full control.
  3. Give the rule a name and a priority. Highest priority down, first match wins.
  4. Add a path condition and set the action to a redirect to your reflink.
  5. Save the rule. It is stored in 301.st but not yet live on the edge.
  6. Open the rule and press Sync to push it to the Cloudflare Worker.

How Path Matching Works

The path field is a raw regular expression. The Worker runs new RegExp(path).test(url.pathname) — an unanchored substring match on the pathname only.

  • /vavada — matches any pathname that contains /vavada.
  • ^/vavada$ — matches only the exact pathname /vavada.
  • ^/promo/ — matches any pathname that starts with /promo/.
  • .* — matches every request. This is a catch-all.

Regex is not glob. /playf* means /playf with zero or more trailing f, not "starts with playf". Use ^/playf for "starts with".

A catch-all (.*) rule must have the lowest priority, or it will swallow traffic before more specific rules are reached.

Leaving the path field empty also matches every request — treat an empty path like a catch-all.

Companion Tool: Geo Tier Builder

Geo Tier Builder is a free browser extension we maintain for building the inputs TDS rules need.

  • Geo lists: assemble tiered country lists and export them for a country condition.
  • Regex helper: generate and live-test a TDS path pattern from plain slugs before you save the rule.

It runs entirely in your browser and never sees your 301.st account.

FAQ

I created a rule but nothing happens. Why?

A saved rule is not live until you sync it. Open the rule drawer and press Sync to push it to the Cloudflare Worker.

Why does my /playf* pattern not behave like a wildcard?

The path is a regular expression, not a glob. Use ^/playf for "starts with", or the regex helper in Geo Tier Builder.

My catch-all rule blocks everything else. How do I fix it?

Catch-all (.*) matches every request. Give it the lowest priority so more specific rules are evaluated first.

Where do TDS rules execute?

On a Cloudflare Worker at the edge, attached to the site's acceptor domain, on every request to that host.

Smart Shield or SmartLink — which should I use?

If the visitor URL carries tracking parameters (utm_source, fbclid, gclid) and you want to route based on them, use SmartLink. For everything else — filtering bots, splitting by country or device, blocking unwanted traffic — use Smart Shield. Both types can live on the same site; they are evaluated in priority order.

Related Guides