Sub topic 13
Test and Optimize While the Campaign Runs
This chapter assumes you have read the earlier chapters on goals, channel roles, budget allocation, and UTM tagging. You should know your campaign KPIs and have a budget split by channel. You should also be able to read a report in your analytics tool.
A seasonal campaign has a fixed end date. You cannot run a test for two months and apply the result next quarter. Testing and optimization have to be quick, narrow, and tied to the goals you set at the start.
Decide what you will watch
Check a short list of numbers on a set schedule. Too many metrics lead to reacting to noise.
| Channel | Leading signal | Outcome signal |
|---|---|---|
| Search | CTR, impression share | Conversions, cost per conversion |
| Social | CTR, cost per click | Conversions, cost per conversion |
| Open rate, click rate | Conversions, revenue per send |
Leading signals show up within hours. Outcome signals take longer. Early in the window, use leading signals to catch broken ads or weak creative. Later, judge by outcomes.
Because every link carries the same utm_source, utm_medium, and utm_campaign values, you can compare all three channels in one report. If a channel's numbers look wrong, check the tags first.
Test one thing at a time
Change one element per test: a headline, an image, a subject line, or a call to action. If you change two things, you cannot tell which one caused the result. Use utm_content to label each variant, for example headline_a and headline_b.
Before you start, write down three things:
- The metric that decides the winner.
- The minimum amount of data you need, such as 100 clicks per variant or a full email send.
- The date you will make the call.
Writing the rule first stops you from picking a winner just because it looks good on day two.
def pick_winner(a_clicks, a_conv, b_clicks, b_conv, min_clicks=100):
if a_clicks < min_clicks or b_clicks < min_clicks:
return "keep running"
rate_a = a_conv / a_clicks
rate_b = b_conv / b_clicks
if rate_a == rate_b:
return "tie"
return "A" if rate_a > rate_b else "B"
print(pick_winner(240, 12, 260, 21))
# BThis helper only enforces a minimum sample. It is not a significance test. For close results, use a proper test in your ad platform or a statistics tool before you declare a winner.
Reallocate spend with evidence
Your budget shares were a starting estimate. Move money when the data gives you a reason. A common rule is to shift a small fraction at a time, such as 10 percent of a channel's remaining budget, and re-check after a few days.
def shift_budget(budget, from_ch, to_ch, fraction=0.10):
amount = budget[from_ch] * fraction
budget[from_ch] -= amount
budget[to_ch] += amount
return budget
remaining = {"search": 6000.0, "social": 4500.0, "email": 1500.0}
print(shift_budget(remaining, "social", "search"))
# {'search': 6450.0, 'social': 4050.0, 'email': 1500.0}The total stays the same, so the plan still adds up.
Common errors
- Calling a test too early. Small samples swing widely. Wait for your minimum.
- Judging by clicks alone. A cheap click that never converts wastes budget.
- Ignoring the phase. Early in the window, awareness ads will look weak on conversions. Compare each channel to its own role.
- Changing many things at once. You lose the ability to explain the result.
- Forgetting to record changes. Keep a log with the date, the change, and the reason. You need it for the post-campaign review.
Keep the message consistent
If a headline wins in search, consider whether the same idea suits the social ad and the email subject line. Carry the winning angle across channels, but keep the core offer and dates identical everywhere.
Exercise
Your campaign has run for four days. Social variant B has 40 clicks and 6 conversions. Variant A has 45 clicks and 2 conversions. Your rule requires 100 clicks per variant. What should you do, and why?
Show answer
Keep both variants running. Neither has reached the 100-click minimum, so the difference could be chance. Check the date you set for the decision and look again when each variant has enough data.
Exercise
Search is converting at half the cost of social, with 3 weeks left. How should you move budget, and what should you do afterward?
Show answer
Shift a small fraction, such as 10 percent of social's remaining budget, to search. Then wait a few days and re-check cost per conversion for both channels before moving more. Record the change and the reason in your log.