Email Split Testing for Developers
Email split testing for developers usually means wiring up an ESP API, building variant tables, and hand-rolling significance math. marginal collapses that into a hosted email MCP server your editor or agent calls directly — generate variants, launch a test, read the lift, and pick a winner without leaving your workflow.
Why split testing belongs in your dev workflow
Most split-testing tooling is built for marketers clicking through a dashboard. That leaves developers stitching together cron jobs, tracking pixels, and ad-hoc statistics whenever they want to compare two subject lines. The result is brittle and rarely reproducible.
marginal exposes split testing as MCP tools instead of a UI. Your AI coding assistant — Cursor, Claude Code, Windsurf, or any MCP client — can run a subject line A/B test as a structured operation, the same way it reads files or runs a build.
- No dashboard context-switching during a build session
- Tests are described as tool calls, so they're easy to script and version
- Open/click tracking and within-test lift metrics are handled for you
The four MCP tools that run a test
marginal's email MCP server ships a small, composable tool surface. Each step of a split test maps to one call, which makes it predictable for both humans and AI agents.
- generate_variants — produce candidate subject lines to compare
- launch_test — start a managed send that splits recipients across variants
- get_results — pull opens, clicks, and within-test lift as the test runs
- recommend_next — get a data-backed call on which variant to keep
Letting an AI agent drive the experiment
Because the server speaks MCP, AI agent email marketing becomes a natural extension of your existing assistant. You can ask your agent to draft three subject line options, launch the A/B test, and report back the winner once enough data lands — all without you touching an ESP console.
marginal is fully hosted, so there's nothing to self-host or deploy. You authenticate with a Bearer API key (marg_live_...) and point your client at https://marginal.sh/mcp. The free tier includes 100 experiments per month, which is plenty for iterating on transactional and lifecycle emails during development.
- Connect any MCP client: Cursor, OpenAI Codex, Claude Desktop, Cline, Continue, Zed
- Endpoint: https://marginal.sh/mcp with bearer-token auth
- Docs and tool references live at https://marginal.sh/docs/
A typical subject line A/B test
A complete loop reads cleanly as a sequence of tool calls. The agent proposes variants, you approve, and the test runs against a managed send with tracking baked in.
Once results stabilize, recommend_next translates raw opens and clicks into an actionable choice — so email split testing for developers stops being a statistics project and becomes a single confident decision.
- Call generate_variants for two or three subject lines
- launch_test to split your list and begin sending
- Poll get_results for live open/click and lift numbers
- Use recommend_next to lock in the winning variant
Get started with marginal
marginal is a hosted email marketing MCP server at marginal.sh. Sign up free, create an API key, and connect https://marginal.sh/mcp from Cursor, Codex, or Claude Desktop.
- 100 experiments/month on the free tier
- Four MCP tools: generate_variants, launch_test, get_results, recommend_next
- Listed in the MCP Registry as sh.marginal/mcp