Guide

AI pair programming: what it is and how to do it well

An AI can write the code. Pairing means you still steer it and understand what it wrote. The origins, the evidence and the habits that work.

AI pair programming means writing code with an AI assistant as your partner: the AI suggests or writes the code, and you steer, review and understand every change, the way a navigator works with a driver in classic pair programming. GitHub introduced Copilot in June 2021 as "your AI pair programmer", and the term now covers editor assistants and terminal agents alike. It differs from vibe coding, where you accept code without reading it. The evidence on speed is mixed: GitHub measured developers finishing a task 55% faster in 2022, while METR's 2025 trial found experienced developers 19% slower on their own projects.

Key takeaways

  • Pair programming comes from Extreme Programming: a driver at the keyboard, a navigator reviewing and thinking ahead. With AI, you are the navigator.
  • If you reviewed the code, tested it and can explain it, it isn't vibe coding.
  • Controlled studies range from 55% faster to 19% slower, depending on the task and the developer.
  • Handing over the thinking has a cost: in Anthropic's 2026 study, developers who used AI scored 50% on a follow-up quiz against 67% for those who didn't.
  • Thoughtworks advises against replacing human pairing with AI; Canva, Google and Meta have brought AI into coding interviews.

Where does the term come from?

Classic pair programming is two people writing code together at one machine. The driver types and focuses on the next small step; the navigator reviews as the code is written and keeps the bigger picture in mind. Kent Beck made it a core practice of Extreme Programming in the late 1990s (martinfowler.com).

The AI version arrived on June 29, 2021, when GitHub announced Copilot as "your AI pair programmer" (GitHub). Aider, an open-source terminal tool, still calls itself "AI pair programming in your terminal" (Aider). In 2026 the tools mostly call themselves agents, but the working relationship is the same: the AI drives, you navigate.

Does AI pair programming make you faster?

It depends on the task, the codebase and the developer.

Studies of AI-assisted coding, from each publisher's own report.
StudyWhenWhoResult
GitHub controlled experimentSeptember 202295 developers writing an HTTP server55% faster with Copilot
Google randomized trialOctober 202496 Google engineersAbout 21% less time, with a wide margin
METR randomized trialJuly 202516 experienced open-source developers, 246 real issues19% slower with AI
METR rerunFebruary 202657 developers, 800+ tasksInconclusive; METR called the signal unreliable
Anthropic skills studyJanuary 202652 mostly junior engineersNo significant speedup; quiz 50% vs 67% without AI
DORA reportSeptember 2025About 5,000 respondentsHigher throughput, less stable delivery

The pattern: AI helps most on well-defined tasks in unfamiliar territory and least for experienced developers in codebases they know well. Google's DORA report found AI adoption now linked to higher throughput but still to less stable delivery (DORA 2025). Its summary: AI amplifies whatever a team already is.

Is AI pair programming the same as vibe coding?

No. Simon Willison drew the line in March 2025: vibe coding means building with an AI without reviewing the code it writes; if you reviewed it, tested it and could explain how it works, that's just software development (Simon Willison). His own rule is never to commit code he couldn't explain to someone else.

Birgitta Böckeler suggests deciding how closely to review from three things: how likely the AI is to be wrong, how much it matters if it is, and whether you would notice (martinfowler.com). A throwaway script can be vibed; a payment flow can't. More in What is vibe coding?

How do you pair with an AI well?

  • Stay the navigator. Set the goal and the next small step, and read each change before it lands.
  • Keep the feedback loop fast. Run the tests often; an AI with a test suite is a better partner than one without.
  • Timebox. When the AI goes in circles, stop, clear the context and restart with a sharper request.
  • Ask it to explain. In Anthropic's study, developers who used AI to understand the code kept their skills; those who handed the work over didn't (Anthropic).
  • Fix the setup, not just the output. When the AI keeps getting something wrong, improve the instructions, specs and tests it works from.
  • Keep pairing with people. Böckeler argues assistants don't replace human pairing, which spreads knowledge and shared ownership of the code (martinfowler.com). Thoughtworks' Technology Radar puts "replacing pair programming with AI" on Hold (Thoughtworks).

What are the AI pair programming tools in 2026?

  • In the editor: GitHub Copilot, Cursor (rebuilt around agents in Cursor 3, April 2026), Devin Desktop (Windsurf's new name since June 2026) and JetBrains AI, whose Junie agent left beta on June 17, 2026.
  • In the terminal: Claude Code, Codex CLI, Copilot CLI (generally available since February 2026), Antigravity CLI (which replaced Gemini CLI for personal Google accounts) and Aider.

Compared in Claude Code alternatives, Cursor alternatives and Claude Code vs GitHub Copilot.

Can you use AI in a coding interview?

At more companies than before:

  • Canva expects candidates for backend, machine learning and frontend roles to use AI tools such as Copilot, Cursor and Claude in interviews (Canva).
  • Meta was building a coding interview with an AI assistant, 404 Media reported in July 2025 (404 Media).
  • Google is piloting Gemini in a code comprehension round for some junior and mid-level US roles from the second half of 2026, Business Insider reported in May 2026 (Business Insider).
  • Amazon told recruiters in 2025 that candidates using AI tools without permission may be disqualified.

Check each company's rules before you start; interview platforms such as CoderPad now build AI into the pad.

Mob programming with AI

Mob programming, which Woody Zuill describes as the whole team working on the same thing, at the same time, in the same space, on one computer (mobprogramming.org), is getting the same treatment. The Mob Mentality Show, with Zuill, argued in a July 2026 episode, "AI and the Ensemble", that the group matters more with AI, not less: the shared skill is giving clear intent, whether to a teammate at the keyboard or to an agent. Thoughtworks' April 2026 Radar says to adopt curated shared instructions for a team's coding agents, and to assess how well people and agents collaborate, not only how fast they go.

Pairing with AI as a team

Classic pairing is two people and one keyboard. With agents it becomes two or more people and one agent: one person states the goal, others watch the plan and the diffs, and someone checks each change. Most AI tools seat one person, so the others watch over a shoulder or a screen share.

Poly (usepoly.co) is built for that shape: a browser room where a team works with one coding agent, Claude Code or Codex. Everyone sees each step live, the agent asks before it acts, and any member can approve or undo a change. Free to start. What is multiplayer agentic coding?

Common questions

What is AI pair programming?

Writing code with an AI assistant as your partner: the AI suggests or writes the code, and you steer it, review each change and understand what it wrote, like the navigator in classic pair programming.

Is AI pair programming the same as vibe coding?

No. Vibe coding means accepting AI-written code without reviewing it. If you reviewed the code, tested it and can explain how it works, it is AI-assisted programming, not vibe coding.

Does AI pair programming make developers faster?

Sometimes. GitHub measured 55% faster on a defined task in 2022 and Google about 21% in 2024, but METR found experienced developers 19% slower on their own projects in 2025.

What are the best AI pair programming tools?

In the editor: GitHub Copilot, Cursor, Devin Desktop and JetBrains AI. In the terminal: Claude Code, Codex CLI, Copilot CLI and Aider.

What is mob programming with AI?

A whole team working on one task at one computer, with an AI agent as part of the group. The team agrees on intent and reviews the work together while the agent writes the code.