How to track ad responses with a click-tracker

If you engage in any type of advertising on the Internet (for example, placing ads in ezines or buying AdWords traffic) then a click-tracker is an essential tool for determining which ads are generating traffic and which aren't.

I'm going to show you how to set up a click-tracker and it won't cost you a single penny! You could always pay a monthly fee and join one of the many services that will help you track your ads, or you can do what the pros do and have your own click-trackers running on your own domain.

You'll need your own hosting account with PHP for this to work. Don't worry if you've never used PHP before, if you can upload files to your web space then you'll have no problems here. A PHP file is no different from an HTML file in this respect - if you can upload web pages then you can get PHP scripts up and running just as easily.

In this example I'll assume you're placing the same ad in two different ezines and want to track the response generated by each. I'll also assume your domain is "".  Obviously you can change these details to fit your own circumstances.

Ok, let's get started.

Go to, click "mailing list" in the navigation bar at the top and subscribe, then check your email for the password. This will give you full access to all the scripts. Click on "Free Scripts" in the navigation bar and then click on "Tagged Click Tracker". Now fill out the form as follows:

Password: showstats (note that you should always choose a password that is a random combination of letters and numbers, but as this is just an example we'll use "showstats").

Destination URL: Enter the URL of the website you want to advertise (could be an affiliate URL for example, or your own website).

Optional Expiration: Leave this box as it is. We don't want the link to expire.

Name: go (note that when creating your own click-trackers you should give each a different name and keep it as short as possible).

You can leave all the other boxes as they are, unless you understand what they do.

Now hit "Submit". Follow the instructions on the next page, where you'll be asked to save several files on to your computer and then upload them to your web space and change the permissions. Upload them to the root directory, which is where your "index.html" file goes. You can upload these files anywhere, but for this example we'll upload to the root directory.

Once uploaded, follow the instructions for changing the permissions of the specified file.  If you've never changed file permissions before then don't worry, here's a guide that simplifies this already simple task:

Now you're all set! You can view the statistics for this click-tracker by going to:

When it comes to placing your ezine ads, the first ad should have the following URL:

The second ad (in the second ezine) should have this URL:

Now when you view the statistics for this click-tracker, you'll see how many clicks were generated by each ezine.  This is because each of the two URLs above are "tagged".  The first one is tagged with "ezine1", and the second is tagged with "ezine2".  Each tag has its own set of statistics, so you can easily determine which ezine ad generated the most clicks.  The "tags" can be anything you want, just make sure you use alphanumeric characters only (no spaces or symbols).  You can also have up to 1000 tags per click-tracker.

Not only that, but you can also enter the number of sales achieved for each tag, the amount spent and the amount earned. The click-tracker then automatically generates the conversion ratio and ROI (return on investment) for each tag, as well as the overall conversion ratio and ROI.  Now, if that didn't make any sense to you then don't worry, a simple example will reveal all.

It's your ROI which matters

Let's assume you're advertising an affiliate program in your ezine ads and you earn $50 per sale. Let's also assume that you got 100 clicks on the ad in the first ezine (tagged with "ezine1", as explained above) and 150 clicks on the ad in the second ezine (tagged "ezine2"). The first ezine ad cost $25 and the second ad cost $60. Finally, the first ad generated 1 sale, while the second generated 2 sales.  In other words:

ezine1 - $25 spent, 100 clicks, 1 sale, $50 earned.
ezine2 - $60 spent, 150 clicks, 2 sales, $100 earned.

Now after you enter this data into the click-tracker, we see the following information generated for us:

ezine1 - conversion ratio=1%, ROI=100%
ezine2 - conversion ratio=1.33%, ROI=66.66%

The conversion ratio tells us how many people bought the product, relative to the number of people we sent to the affiliate site. In the case of "ezine1", we sent 100 people and made one sale, a conversion ratio of 1% (because 1% of 100 is 1). In the case of "ezine2", we sent 150 people and made 2 sales, a conversion ratio of 1.33% (because 1.33% of 100 is 2).

The return on investment is simply the amount of profit made expressed as a percentage of the amount spent. For example, if you spent $100 and got back $100, the ROI is 0%, because no profit has been made. If you spent $100 and got back $150, the ROI would be 50%, because the profit ($50) is 50% of the amount spent ($100).

We can now see that "ezine1" is the best deal because it has the highest ROI. Whilst "ezine2" generated a higher conversion ratio, the ad cost more than twice as much as "ezine1", putting a large dent in the ROI. The ad in "ezine1" only cost $25, generating a return of 100%, even though the conversion ratio was only 1%.

Tracking sales

You may be wondering how you can determine how many sales are being generated for each tag. For example, how do you know how many sales "ezine1" generated and how many came from "ezine2"? When you login to your affiliate account you only see 3 sales, but no mention of "ezine1" or "ezine2". Thankfully, affiliate link tracking is available at various affiliate networks which allows us to see where our sales are coming from. I'll use ClickBank as an example here, but the same principle applies to all.

With ClickBank, your affiliate URL looks something like this:

Now, if you were to change XXX to "ezine1" then any sales generated from this link would be assigned to the tracking ID "ezine1". In other words, when checking your ClickBank stats you'll see a list of all the tracking IDs you've used and the number of sales assigned to each one.  One problem though, we want XXX to be "ezine1" when someone responds to our ad in the first ezine, and "ezine2" when they respond to the ad in the second ezine. To achieve this, simply create your click-tracker again but this time, for the "Destination URL", enter the following:[TAG]

The important bit is at the end, where it says [TAG].  This is automatically converted at run-time to either "ezine1" or "ezine2" (or whatever tags you're using when you advertise your click-tracker URL).

Now take a look at your click-tracker URL from the first ad:

When somebody clicks on that link, the "Destination URL" is dynamically converted to:

Now if that person makes a purchase at the affiliate site, it will show up in your ClickBank stats as a sale for "ezine1".

Using click-trackers does involve a certain amount of work to get them set up, but on the plus side it's 100% free and the information they provide is well worth the time and effort. Many hosting accounts come with PHP, even basic accounts. If you have PHP and aren't using it then it's a wasted resource.

April 2, 2007

Comments (11)

Said this on April 5, 2007 At 08:10 am
Great info! Now, is there anyway to pick up the keyword that was searched for, or used to make the sale?
April Kerr
Said this on April 5, 2007 At 08:12 am
This looks great, thanks for sharing this info. I was going to pay for an adtraker for an ebook I'm creating but this seems just as good.
Said this on April 6, 2007 At 09:06 am
In response to "Great info! Now, is there anyway to pick up the keyword that was searched for, or used to make the sale?":

You would need to create a separate tracking link for each keyword. For example, if you're bidding on keywords at a PPC engine, then the destination URL for each keyword would be something like:
...and so on.

You'll then be able to see how many clicks each keyword got and how many sales came from each (assuming your affiliate network has a tracking id facility, like ClickBank's).
Said this on April 6, 2007 At 12:09 pm
Nice info! Would there be a way with this to track Adwords keywords through a 'long chain' conversion process? For example, tag all Adwords ads and retain tracking info through your opt-in list *and* the sale? A side by side comparison of which keywords convert to *subscribers*, and then out of those, which ones convert to sales... would be super useful.
Said this on April 9, 2007 At 06:45 am
In response to: "Nice info! Would there be a way with this to track Adwords keywords through a 'long chain' conversion process?"

I have a free script called a "Conversion Tracker (Click Based)", which you can also download from PHPSuccessTools. It works very much like the click-tracker script described in the article above. The only additional thing you'd have to do (as explained on my site when you download the script) is to put some code on your "thank you" page which they see after opting-in to your list. This would allow you to see which keywords are getting the most clicks and which are converting to subscribers. However, to find out which of those subscribers are then turning into customers - there is a way which involves use of 2 conversion tracker scripts. It's a bit of a long-winded process so maybe that's a subject for another article!

[Another article sounds an excellent idea. Allan.]
Said this on April 9, 2007 At 11:53 pm
Yes, it is a very handy script, however, it is only for tracking links back to your own domain. I was initially hoping that it would track all outgoing links from each affiliate link you have on your site. You probably could do this with this script, but I think it would mean creating a new script for every domain that you want the visitors to be sent to. I.e. would be for each link that you have.
Said this on April 10, 2007 At 02:03 pm
In response to: "Yes, it is a very handy script, however, it is only for tracking links back to your own domain."

The script can be used to track the number of clicks you're getting on any link. It doesn't matter which domain the script is hosted on or which domain you're sending people to, all that matters is the Destination URL you specify during the script set-up - that's where people will be sent.

If you have multiple affiliate URLs on your site then you'd have to create a separate script for each (as you said in your comment). If your domain is and you have 2 affiliate URLs, you could create two scripts - one called script1.php (going to your first affiliate link) and the other called script2.php (going to the second affiliate link). Your affiliate links would then be:


If you have the same link on multiple pages, you could replace "whatever" with the page name, so you know which pages are generating the most clicks.
April Kerr
Said this on April 12, 2007 At 11:07 am
If I used these tracking URLs for inbound links to my site (for example on forums or article directory submissions) would I still have SEO benefits?
Said this on April 13, 2007 At 09:56 am
April, Yes, you still gain SEO benefits as long as the script is hosted on your domain. For example, if you have an article/forum post and the link to your site is, then that's a link to your site the same as any other. If you don't want people to know the link is a PHP script you can just create a folder on your website, rename the script to index.php and put it in the folder. For example, create a folder called "whatever", put index.php in there (index.php being the click-tracker script) then your link would be:

Not sure if you'd get more SEO benefit from doing it that way, maybe an SEO expert could clarify this.
Said this on May 21, 2007 At 07:16 pm
"If I used these tracking URLs for inbound links to my site (for example on forums or article directory submissions) would I still have SEO benefits?"

Just bear in mind that the SEs will generally treat the following three URLs... unique web pages (even if the second and third redirect to the first).

This probably won't matter if you don't want the final destination page indexed (such as when masking an affiliate link), but if you are tracking links to your own page, you will most likely not get the full linking benefits unless the redirect script sends a 301 redirect code.

If a 301 is employed, those links should all act as though they are direct links to the destination page, but otherwise, they will be unique pages which may cause duplicate content problems, as well as splitting the linking benefits.

(Some benefit would obviously be gained as long as those pages link into your main site nav via other links on the page, but that is not the same as having all those links 301ed in.)

To summarize, without 301 redirection from the PHP redirection script, the SE linking benefits to the "real" page will be limited.

This is a general problem with most tracking systems - affiliate links and others.
Said this on November 18, 2007 At 10:35 pm
Will the Clicktracker work to track my domain through CB Mall and its pre-written autoresponder series?

New comments are currently disabled.

Newsletter Sign-up

Sign-up Now!

How to make $1000 a month from scratch

Sign-up for our newsletter and receive our 77 page eBook "How to make $1000 a month from scratch".

Best of all it's FREE!

Your Host

Learn from an affiliate veteran.

Your host, , has been earning a good living from affiliate programs since 1998.

Want a BETTER article writer? We will write good articles just for you.

Content Kingdom