runbookify
← All plans
Sales & CRM / Pipeline & Deal Management

Win/Loss Reason Capture & Insights

Capture a clean, structured reason every time a deal closes - won or lost - and roll it up into loss-reason, win-reason, and competitor trends your team can actually act on.

BeginnerAn afternoonBuilds onNext.js (App Router) on VercelSupabase (Postgres + Auth + RLS)Resend (email)
What you'll build

An internal tool where reps log a structured reason for every closed deal, a manager reviews and approves each record, and approved deals roll up into a trend dashboard plus a clean CSV export.

Gated download

Enter your email — the plan downloads instantly and a copy lands in your inbox.

By submitting your email you'll also receive the weekly runbookify newsletter. You can unsubscribe at any time.

Before you start

  • A list of your closed deals (won and lost) - from a CSV or Google Sheet export
  • Your reason taxonomy: the primary win/loss reasons, competitors, and segments you want to track
  • Free Vercel, Supabase, and Resend accounts

The problem this kills

Right now, when a deal closes, the reason is a shrug. Your CRM says "Lost - Other" and the real story walks out the door with the rep. Maybe it's in a Slack thread. Maybe it's in someone's head. Maybe it's nowhere.

So when your manager asks "why are we losing to Competitor X?" or "which segment closes fastest?", nobody can answer with data. You're guessing. Product builds the wrong thing. Marketing chases the wrong message. And every quarter the same questions come back with the same shrug.

The fix isn't a fancier CRM. It's a tiny, disciplined habit: capture one clean, structured reason every single time a deal closes - and make sure it's good data before it counts.

What you'll build

A small internal web app where:

  • A rep marks a deal closed (won or lost) and fills a short, structured form - a reason picked from your controlled list, the competitor (if any), the segment, the amount, and a free-text note for the detail.
  • A manager reviews and approves each record before it counts: is the reason valid, the competitor tagged, the amount right? Nothing hits your reporting record-of-truth until a human says yes.
  • Approved records roll up into a trend dashboard - loss reasons, win reasons, competitor losses, and slices by segment - so you can finally see the pattern.
  • Everything exports to a clean CSV in the exact columns your downstream reporting expects.

It's the kind of tool you can stand up in an afternoon and have your team using next week.

What's inside the Implementation Plan

The plan is a single file you paste into an AI coding agent (Claude Code). It walks the agent through building the whole tool, step by step, with a ready-to-copy prompt at the end of each step.

It opens by interviewing you about your business. Before a single line of code, the plan makes the agent ask about your current close process, your CRM and spreadsheets, your real reason list and competitor names, your typical and peak deal volumes, your approval rules, and your messy edge cases (reopened deals, partial wins, "no decision" losses). Then it reads a short tailored spec back to you for a thumbs-up. The result is a tool shaped around how you actually work - not a generic template you have to bend yourself into.

Inside you'll find:

  • The discovery interview (8-12 tailored questions) and how the agent turns your answers into the data model.
  • A controlled reason taxonomy that keeps data clean while still allowing free-text detail.
  • The rep capture form, the manager approval queue, and the win/loss record-of-truth.
  • The trend dashboard sliced by reason, competitor, and segment.
  • Login, row-level security, a full audit trail, an approval gate, and duplicate guards.
  • A "No API yet?" fallback so you can build it today from a Google Sheet or CSV and export clean CSV out.

The governance it includes (this is the point)

This isn't a toy. The plan bakes in the controls that make data trustworthy:

  • Login so only your team can use the tool.
  • Row-level security so people only ever see their own organization's data.
  • A complete audit trail - who logged a reason, who approved it, and exactly when.
  • A human-in-the-loop approval gate - the rep drafts, the manager reviews and approves, and only then does the record commit to your win/loss record-of-truth.
  • Duplicate guards keyed on deal ID + close date, so a deal that's reopened and re-closed can't get double-logged and quietly skew your trends.

That's the difference between a spreadsheet anyone can fudge and a record you can take into a board meeting.

Who it's for

Sales managers, RevOps, and the product and marketing partners who keep asking "but why did we lose?" - and are tired of "Lost - Other" being the only answer. If you can fill in a form and follow steps, you can build this. No coding background required.

You've got this. Paste the first prompt and let the agent interview you.

Gated download

Enter your email — the plan downloads instantly and a copy lands in your inbox.

By submitting your email you'll also receive the weekly runbookify newsletter. You can unsubscribe at any time.