squirrelscan
GitHub

Affiliate disclosure: detecting affiliate links without one

Undisclosed affiliate links are a regulatory problem and a trust problem. squirrel detects affiliate link patterns and looks for a disclosure page.

What affiliate disclosure is

An affiliate link earns the publisher a commission when the reader buys. Disclosure is telling the reader that before they click, and in the United States the Federal Trade Commission requires it for any material connection between the endorser and the seller. Other jurisdictions have equivalent rules.

Where it goes matters as much as whether it exists. A line in the footer is not where someone reads before clicking a product link; the disclosure belongs near the links it covers, at the top of the page or beside them.

What squirrel checks

The rule is site-wide. It looks for a disclosure page by URL and, separately, counts pages carrying links that match affiliate patterns. It emits up to two checks:

  • Skipped when no pages were crawled. Message: No pages available for analysis.
  • affiliate-links reports info when affiliate links were found. Message: 12 page(s) appear to have affiliate links.
  • affiliate-disclosure passes when links were found and a disclosure page exists. Message: Affiliate disclosure page found, with the URL.
  • affiliate-disclosure warns when links were found and no page exists. Message: Affiliate links detected but no disclosure page found, with Create /affiliate-disclosure page (FTC requirement) as the value.
  • affiliate-disclosure passes when no links were found but a page exists. Message: Disclosure page exists.
  • affiliate-disclosure reports info when neither was found. Message: No affiliate links or disclosure page detected.

The disclosure page is matched on /disclosure, /affiliate-disclosure, /advertising-disclosure, /sponsored-disclosure or /ftc-disclosure. Affiliate links are matched against seven patterns applied to the whole URL string, not to the hostname: amazon.<tld>/ followed later by tag=, shareasale.com, go.redirectingat.com, awin1.com, commission-junction, ?ref= and ?affiliate=. The Amazon pattern needs the tag to come after a path segment, so a bare amazon.co.uk/?tag=… does not match, and the last two are broad enough that an internal referral parameter will. Severity info, weight 4.

The rule only runs when the audit classified the site as a blog or a news site. A classification below medium confidence, or an audit with no site metadata at all, runs it anyway.

How to fix it

<p class="disclosure">We earn a commission from purchases made through the links below.</p>

Put the sentence at the top of the page, above the links it covers, and keep a dedicated disclosure page linked from the footer for the detail. Use plain language rather than a legal formula.

A ?ref= parameter on an internal link will be counted as affiliate. Check what was matched before concluding you have a disclosure gap.

Rule IDeeat/affiliate-disclosure
CategoryE-E-A-T
ScopeSite-wide
Severityinfo
Weight4/10

Enable / disable

Disable this rule

[rules]
disable = ["eeat/affiliate-disclosure"]

Disable all E-E-A-T rules

[rules]
disable = ["eeat/*"]

Enable only this rule

[rules]
enable = ["eeat/affiliate-disclosure"]

enable replaces the default ["*"], so this is the only rule selected. Leave disable out: a rule that matches any disable pattern is skipped even when enable names it. Only an enabled setting under a rule’s own [rule_options] table overrides both lists.

E-E-A-T findings ship in every audit next to the SEO, performance and agent experience rules. See Fix SEO issues with AI for how an agent works through a report.

References

Check your site

Run squirrel audit https://example.com and open the E-E-A-T section of the report. The site is reported with how many pages carry a matching affiliate link and whether a disclosure page exists. Signed-out local audits need no account and cost nothing. Signed-in audits spend credits.

Type to search…

↑↓ navigate↵ openesc close