Sub topic 5
Getting the right visitors and measuring conversion
A landing-page test only answers your question if the people who see it are the people you want to learn about. This chapter covers where visitors come from, how to tag them, and how to compute a conversion rate. It assumes you know what a customer segment is, can read a simple signup form, and are comfortable with percentages.
Why the traffic source matters
Conversion rate is signups divided by visitors. The visitors are the denominator, so a change in who visits changes the result even when the page stays the same.
Suppose you sell scheduling software to dental clinics. Two hundred visitors from a dental-practice forum and two hundred from a general startup newsletter will convert very differently. The newsletter readers may like the idea but never use it. A high rate from the wrong audience tells you nothing about your segment.
Pick sources that match the segment named in your hypothesis. Common options:
| Source | Strength | Risk |
|---|---|---|
| Paid search ads | Targets people already looking for a solution | Costs money per click, and the keywords you pick shape the audience |
| Social or forum posts in a niche community | Reaches the exact segment | Small volume, and moderators may remove posts |
| Direct outreach (email, calls) | Highest relevance | Contacts often feel obliged to be polite |
| Friends and personal network | Fast and free | Not your market, see the pitfalls chapter |
Tag every visitor by source
If you mix all traffic into one number, you cannot tell which source worked. Record the source with each signup. The simplest way is a hidden form field set per source, with a separate link or page variant for each channel.
<form action="/signup" method="post">
<label for="email">Email</label>
<input id="email" name="email" type="email" required>
<input type="hidden" name="source" value="newsletter_a">
<button type="submit">Join the waitlist</button>
</form>For each channel you publish, change the value (for example forum_dental, search_ad_1). You also need a visit count per source. Many analytics tools provide this through UTM parameters, which are tags added to the end of a link, such as ?utm_source=forum_dental. Without a visit count per source, you cannot compute a rate per source.
Define the metric before you launch
The main metric is the conversion rate for the action that costs the visitor something. Joining a waitlist is cheap. Giving a phone number, booking a call, or paying a deposit is stronger evidence of demand. Decide which action counts, and write it with your success threshold from the earlier chapter.
Computing the rate
For one source: conversion rate = signups from that source ÷ unique visitors from that source.
Say 400 visitors arrive from a dental forum and 18 sign up. The rate is 18 / 400 = 4.5%. Compare that with the threshold you set in advance, for example "at least 3%". A single percentage hides how uncertain it is, so also compute an interval. The next chapter explains how to read it. The code below calculates a 95% Wilson confidence interval.
import math
def wilson_interval(successes, n, z=1.96):
if n == 0:
return (0.0, 0.0)
p = successes / n
denom = 1 + z**2 / n
centre = (p + z**2 / (2 * n)) / denom
margin = z * math.sqrt(p * (1 - p) / n + z**2 / (4 * n**2)) / denom
return (centre - margin, centre + margin)
low, high = wilson_interval(18, 400)
print(f"conversion 4.5%, 95% interval {low:.1%} to {high:.1%}")Run it per source, not only on the total.
The flow from click to signup
Common errors
- Counting visitors from one source and signups from all sources. The two numbers must come from the same group.
- Changing the page or the ad copy halfway through. Then you are comparing two different tests.
- Ending the test when the number looks good. Fix the visitor count or the end date first.
- Buying cheap, broad traffic. It produces many visits and few real prospects.
Exercise
A test page gets 300 visitors from a niche forum and 12 signups, and 1,200 visitors from a broad social ad and 24 signups. Your threshold is 3%. Compute the rate for each source and say which result you would trust more for your target segment.
Show answer
The forum rate is 12 / 300 = 4.0%. The social ad rate is 24 / 1,200 = 2.0%. Only the forum meets the 3% threshold. The forum audience matches the target segment more closely, so that result is more relevant, though 300 visitors is a small sample and you should check its interval. The combined rate of 36 / 1,500 = 2.4% would hide this difference and wrongly suggest failure.