Website & conversion · Step 2 of 3
Plan and build experiments
Know how long a test needs before you start it.
Most small-brand A/B tests end too early and declare a winner by chance. Claude works out the sample size and run time from your real traffic, tells you which tests are realistic, and builds the page variants in code so you can launch quickly.
How it works
- Pick a test from your experiment log.
- Claude writes the test plan, including whether you have enough traffic for a reliable answer.
- Claude Code builds the variant, as a page or section you can drop into your site or testing tool.
- You launch and leave it alone until it reaches the planned sample size.
Prompt 1: Test plan
Run it in: Claude Code, or Claude chat with your files uploaded
Prompt 1: Test plan
Write a test plan for this experiment from my backlog: [paste the row]. My numbers: - Weekly visitors to this page: [number] - Current conversion rate: [%] - Smallest lift worth detecting: [e.g. 10% relative] Using Claude Code, work out: 1. The sample size per variant for 95% confidence and 80% power, and how many weeks that takes at my traffic. 2. If it would take longer than 6 weeks, say so and suggest how to make the test viable: a bigger change, a higher-traffic page, or a metric higher up the funnel. 3. The primary metric, one or two guardrail metrics (e.g. average order value), and what counts as a win. 4. What could skew the result (promotions, holidays, traffic mix changes) and how to avoid it. 5. The decision rule: what we do if it wins, loses or is flat.
Prompt 2: Build the variant
Run it in: Claude Code (or Claude chat for the copy, then build it in your site tool)
Prompt 2: Build the variant
Build the variant for this test: [paste the hypothesis and the change]. The current page: [URL, or paste the HTML/section code] My site is built with: [e.g. Shopify, Webflow, Lovable, custom React] Messaging house: [paste or attach] 1. Write the new copy first and show it to me before building. 2. Then build the variant as [a full page / a section I can paste in / code for my testing tool], matching the existing styles. 3. Keep it accessible and fast on mobile. 4. List exactly what to change on the live site to run the test, and how to roll back.
Run one test per page at a time, and change one big thing per test. On low traffic, test bolder changes; small tweaks need traffic you probably don't have.