December 15, 2021 7597

Cookie Stuffing in 2024 — Tutorial + Ideas + Script

Cookie stuffing, also known as forced clicks, cookie sprinkling, or cookie dropping, is a method used in Blackhat marketing (unethical but not always illegal) by affiliate marketers to keep a record of tracking cookies on the end user’s machine. All of this is done without taking proper consent of the user before doing so. Cooking stuffing is done with the intention of making an impression that the user or customer's unique referral link is to be attributed to the Blackhat affiliate’s marketing methods.


How Does Cookie Stuffing Work and Its Relation to Affiliate Marketing?

In affiliate marketing, the affiliate tracking systems have to pay a certain amount of commission to independent websites also known as affiliates when a user clicks through these independent websites' unique links to go to affiliate merchants. Merchants are not obligated to pay someone a commission when a user just visits the affiliate website. Instead, a merchant becomes obligated to pay someone a commission only in case of three events which are:

  1. A user visits an affiliate’s website;
  2. The user clicks through an affiliate link to go to a merchant's website;
  3. And lastly makes a purchase (product or service) from that merchant's website.

Now, this is the step where cookie stuffing comes in. Some affiliate marketers decide to resort to the method of cookie-stuffing to make affiliate merchants’ tracking systems declare that a visitor has clicked through a tracking link to complete a specific action (and then pay the affiliate marketers their commissions accordingly) even if the visitor has not actually clicked on any tracking link to a merchant's website. Under normal circumstances, if a visitor subsequently buys something from a merchant's website or within the “return days” time set by the merchant’s affiliate program, the affiliate marketer gets his commission (only when the user makes a purchase). Cookie stuffing speeds up the entire process.


JavaScript

The most basic cookie stuffing script for JAVASCRIPT is the popup. For a popup, use the following script:

<script type="text/javascript">
window.open("http://www.affiliatesite.com/",'width=200,height=100');
</script>

However, if you want to use a popunder, copy and paste the popunder script from Pastebin, and you are good to go.


iFRAMING

In iFraming, you have to insert a website within another website. You need to place your affiliate website or affiliate link in the iframe for cookie stuffing to get it shown on another page. This link of yours will drop a cookie on any user who goes to that particular page. Here's a script for iFrame:

<iframe src="http://www.affiliate-site.com" width="1" height="1"></iframe>

The width=1 & height=1 mean that the iframe will be 1 by 1 in pixels so that it will be virtually unseen.


Image Cookie Stuffing

Image cookie stuffing is the easiest cookie stuffing method. You just have to place a link or an image tag on others' websites. Image cookie stuffing works by placing an image (for instance, /image.jpg) on someone's website that the website considers an actual image and tries loading it once the page is loaded. In reality, what the website does is load the affiliate marketer's website via the image.

Here is a script for image cookie stuffing; add this script to your .htaccess file on your server:

Redirect /image.jpg http://www.yoursite.com/affiliate_redirect.php

And use this image code:

<img src=”http://yoursite.com/image.jpg”></img>

Redirection with PHP

Redirection with PHP just redirects a user to your own affiliate website, which will then place a cookie. Use this cookie stuffing script at the top of your website's homepage. Keeping in mind that this is a PHP script, you need to make sure that your file or website is also PHP for this script to work. Let's have a look at the script:

<?php header(“Location: http://youraffiliatelink.com ");?>

Cookie Stuffing with Scrapebox

People mostly use Scrapebox to build a huge number of backlinks for their websites easily. Plus, it does not take a lot of time, so they save their time. However, with the passage of time, Google starts tracking this method, and the continuous mass comment spamming comes to an end as quickly as it builds backlinks. That being said, Scrapebox is still a fantastic tool to get valuable links out of millions of websites overnight. And that is where the trick lies. Instead of using Scrapebox to get millions of backlinks, you need to promote your affiliate website.

Do keyword research, scrape as many websites as you can, and try to hit the 1 million mark, which is Scrapebox's limit. Once you have done your research, create a small sales pitch and link it to your URL number 1 instead of creating a fake comment. This way, you will be able to trick people into clicking on your link, which is the purpose of using Scrapebox. The more websites you comment on, the higher the probability of people clicking on your links and helping you earn higher commissions.

So, for example, if you scrape 1 million websites and out of those 1 million websites you manage to leave comments on 5%, that will be 50 000 websites with your sales pitch or unique link in their comments section. So, even if you get only 1 visitor per link or sales pitch, you still garner 50 000 visits without doing anything!

And how does the cookie stuffing work with Scrapebox? Let's find out together:

Your unique link or URL number 1 will go straight to a "dummy" website. From that dummy website, the link will then lead to your main website. Once on your main website, the URL will then redirect to the affiliate site.

Now:

  1. Using nullrefer, you will remove your referrer for URL number 1 and the "dummy" website. It is actually quite simple to do. All you need to do is add this link before your URL: http://nullrefer.com/?
  2. In the "dummy" website, you will only have to add a quick redirect script in order to redirect a user to your main website. This redirect link will look like this:
<?
$referrer = $_SERVER['HTTP_REFERER'];
if (preg_match("/nullrefer.com/",$referrer)) {
header('Location: http://nullrefer.com/?http://www.yourmainsite.com');
};
?>
  1. On your main website, you will now finally redirect users to the affiliate link with the help of the code given below. This code will go in the header of your website:
<?
$referrer = $_SERVER['HTTP_REFERER'];
if (preg_match("/nullrefer.com/",$referrer)) {
header('Location: http://www.affiliatesite.com');
};
?>

Common Cookie Stuffing Ideas

Let's look at some common cookie stuffing ideas.

  • iFrame or Image Cookie Drops

In this method of cookie stuffing, you drop a 1×1-pixel iFrame or image on your website that helps load your unique affiliate link. From a visitor's point of view, your iFrame or tiny image is invisible, but the visitor interacts with your affiliate cookie via their computer. In return, you get to make money off the purchase made by the visitor for every cookie that you drop.

  • WordPress Plugins

You can also find plenty of WordPress plugins that do the same thing as above. The only difference is that the WordPress plugins do it in an automated way across the posts you select or all of them based on your decision.

  • Malware or Browser Toolbars

In the eBay case, Shawn Hogan used browser toolbars (created by him) to make use of cookie stuffing. You may never know, but some computer software you download for free does the cookie stuffing on your computer every time you use it.

  • Adobe Flash & Flash Components

Everyone who uses a computer and the internet knows that Flash is not secure. You can use Flash to load affiliate links both on your personal website and third-party websites

  • Pop-Ups or Pop-Unders

Even though internet browsers can easily block them, they are still used to stuff cookies by tons of people.

These are some common methods used by affiliate marketers for cookie stuffing. However, it is important to know that cookie stuffing works the best for more extensive affiliate programs such as eBay or Amazon. Most of the people living in the US prefer to buy stuff from Amazon and do it regularly (as evident from the TikTok videos showing Amazon Hauls), so you can stuff cookies to earn commissions from the users of Amazon every time they check out at Amazon.com. And the best part is that you can earn the commissions even if you have never actually taken the user to any Amazon page.


Conclusion

And there you have a comprehensive guide to Cookie Stuffing, including a step-by-step tutorial about stuffing cookies using Scrapebox, some amazing scripts for all methods of stuffing cookies, and the most commonly used methods of cookie stuffing. Now, you have all the information you need to start making jaw-dropping commissions via affiliate marketing without having to do a lot of work.

However, before you start venturing into cookie stuffing, keep in mind that not only is it unethical, it can also get your affiliate accounts banned. So, be careful when cookie stuffing.

Do you think cookie stuffing should be legal?
57 votes

 

How do you like the article?
#cookie stuffing