Pair Programming

Two people on one machine for higher quality output, faster learning, and intense focus

Farhan Thawar
How Shopify builds a high-intensity culture

Pair Programming

"It is the most underutilized management tool in engineering, bar none. It is just not used as much as it could be." - Farhan Thawar

What It Is

Pair programming puts two people on one computer—two keyboards, two monitors, but one machine. They work together on the same code, switching who's typing (the "driver") while the other navigates and thinks ahead.

The famous objection: "Won't they write half as much code?" The answer: "They'll write even less than that—because that's not the point."

The throughput limiter in software isn't hands-on-keyboard. It's finding the elegant solution. Pair programming optimizes for solution quality and learning, not lines of code. And in the long run, less code with higher quality moves you faster.

How It Works

Why It Creates Intensity:

  • You literally cannot check Twitter or Slack when someone's watching
  • Exhausting: people sleep 10-12 hours the first few nights
  • Constant engagement keeps focus high
  • Social accountability beats willpower

Why It Creates Quality:

  • Two perspectives catch more mistakes
  • Continuous code review as you write
  • Forces articulation of reasoning
  • Pathfinding happens together

Toby Lutke's Extreme Version: At early Shopify, Toby and CTO Cody would:

  • Set a timer for one hour
  • If they couldn't finish the feature in one hour, delete all the code
  • Keep the tests, start over
  • Reasoning: if you can't write it in an hour, you're on the wrong design

The Pivotal Labs Rule: If your pair was sick and you wrote code solo, your pair would come in the next day and delete everything. Then you'd rewrite it together. What better time to rewrite code than right after you've written it?

How to Apply It

For Full-Time Pair Programming (like contract shops):

  • 40 hours per week of pairing
  • Clear specs and requirements
  • Maximum intensity and knowledge transfer
  • Works when you know exactly what to build

For Pathfinding Companies (like Shopify):

  • 4-8 hours per week of pairing
  • Strategic pairing on critical problems
  • During incidents or debugging
  • Once you've figured out what to build, then pair to build it fast

With AI:

  • AI copilots (GitHub Copilot, Cursor) are now your pair programmer
  • Voice-to-code using Whisper—talk through the problem, AI writes code
  • Even better: AI copilot + two humans together
  • You never have to code alone

The Underhanded Free Throw Problem

The underhanded free throw is statistically proven to sink more baskets. But nobody does it because it looks dumb—including Shaquille O'Neal, who was famously bad at free throws.

Pair programming has the same problem: it looks like a waste (two people, one computer) even though it produces better results. The people willing to look dumb get the advantage.

When to Use It

  • Building critical infrastructure
  • During incidents and debugging
  • Onboarding new team members
  • When you've done the pathfinding and know what to build
  • Whenever focus and quality matter more than raw output

Source

  • Guest: Farhan Thawar
  • Episode: "How Shopify builds a high-intensity culture"
  • Key Discussion: (00:22:07 - 00:28:35) - Why pair programming is underutilized
  • YouTube: Watch on YouTube

Related Frameworks