https://github.com/davegallant/rfd-affiliate-stripper
a browser extension that strips affiliate redirects on RFD
https://github.com/davegallant/rfd-affiliate-stripper
canadian chrome firefox privacy redflagdeals rfd tampermonkey
Last synced: 5 months ago
JSON representation
a browser extension that strips affiliate redirects on RFD
- Host: GitHub
- URL: https://github.com/davegallant/rfd-affiliate-stripper
- Owner: davegallant
- License: mit
- Created: 2021-12-28T02:49:38.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2025-12-13T15:08:50.000Z (6 months ago)
- Last Synced: 2025-12-24T20:29:05.825Z (6 months ago)
- Topics: canadian, chrome, firefox, privacy, redflagdeals, rfd, tampermonkey
- Language: JavaScript
- Homepage:
- Size: 368 KB
- Stars: 5
- Watchers: 3
- Forks: 3
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# rfd-affiliate-stripper
Strips affiliate redirects from deal links posted on RFD.
On every page load, it transforms a link with tracking such as
```
http://www.amazon.ca/gp/redirect.html?ie=UTF8&location=https%3A%2F%2Fwww.amazon.ca%2Fdp%2FB09YXY3DKN%3Fref%3Dcm_sw_r_apan_dp_NX4HJ8HZ3XX2YK1J900A%26ref_%3Dcm_sw_r_apan_dp_NX4HJ8HZ3XX2YK1J900A%26social_share%3Dcm_sw_r_apan_dp_NX4HJ8HZ3XX2YK1J900A%26starsLeft%3D1%26skipTwisterOG%3D1&tag=redflagdealsc-20&linkCode=ur2&camp=15121&creative=330641
```
into
```
https://www.amazon.ca/dp/B09YXY3DKN
```
## Why?
This helps navigate around broken links when using certain adblockers.
## Building the extension
To build the extension, run:
```sh
npm install
npm run build
```
## Updating redirects
The browser extension will update the list of redirects by periodically fetching the latest [redirects.json](redirects.json).
Open a pull request to this repo to update the redirects.
An easy way to test regex: [regex101.com](https://regex101.com/).
New config can be tested by pointing the config url of the extension to your own branch.
For example:
```text
https://raw.githubusercontent.com/davegallant/rfd-affiliate-stripper/my-new-branch/redirects.json
```
## Tampermonkey Script
This was originally a [Tampermonkey](https://www.tampermonkey.net/) userscript before evolving into a browser extension.
To use as a tampermonkey script, copy [script.js](./script.js) into Tampermonkey.

