How The Match Works

As I wrote in PANIC! At the ERAS, the final step in obtaining a spot in a residency program is the Match. Like I mentioned, after all the interviews everyone’s preferences – and the preferences of all of the programs – go into a big computer and get processed through some algorithm, which somehow pops out a “best match.” This process is administered by one central service, called the National Resident Matching Program, or NRMP, so they control everything from start to finish.

Everyone finds out about where they will spend their time in residency at the same time, on the same day, all across the country.

Pretty crazy.

I used to think the formula for the Match was secret and proprietary, but like most of what I have learned over the past four years, this is wrong. The algorithm isn’t secret – it’s the tweaks, extra matches, and verifications the NRMP performs for special groups like couples that makes it special.

But let’s talk about the regular old Match. To give you an idea of scale, last year about 35,000 applicants submitted rank lists to the NRMP for just under 28,000 spots. That number represents the total number of residency spots in the country – all programs, all specialties. Before you freak out that your favorite blogging medical student aka blood relation won’t match, know that just about 94% of American medical graduates match. The drop-off is for international graduates and reapplicants.

Okay, enough numbers. So how, exactly, does the Match work?

The answer is far less complicated than the math behind it (which we aren’t going to cover – you’re welcome), and simple enough for me to explain it using stick figures, dinosaurs, and puppies. Again, you’re welcome.

The equation used by the Match is a variation of a game called the Stable Marriage Problem. Think of the Stable Marriage Problem as a less sadistic/evil version of the Prisoner’s Dilemma, which you’ve probably heard of.

The Stable Marriage Problem asks, “how do you take two equally-sized sets of people – let’s say for the sake of simplicity men and women – and pair them up into the most number of stable marriages possible?” That is, how do you make man-woman pairings* where a man in one marriage and a woman in another don’t both prefer the option to cheat with each other?

*I swear to god if someone makes a comment about political correctness…

A drawing might help illustrate this. Here is a well-matched set of pairs:


In this example, every person is in a stable relationship. There may be cases where the man would rather be with a different woman, but the woman is either satisfied or wants to be with a third man.

But if you have some Romeo and Juliet-esque shit going on…


In this case, the two pairings that include Romeo and Juliet are unstable – that is, there exists a better pairing that puts Romeo and Juliet together. This is a poorly matched set. A Bad Match.

Make sense?

The analogy doesn’t work exactly for the Match, because each program usually has multiple spots instead of just one-for-one. You would think this makes things a lot more complicated, but surprisingly that’s not the case; just imagine each spot for each program as representing one ‘female,’ and each applicant representing a male.

Or vice versa. Or use dinosaurs and puppies, I don’t care. (foreshadowing!)

 Let’s take a given specialty, and a given program; let’s say we’re talking about emergency medicine (surprise!) and an imaginary program, Genocidal Maniac Hospital at Tiller University, named after my idiot dog. This is my idiot dog, who has cleansed multiple zip codes of their bunny populations:


I know, he’s cute, but… this is my idiot dog after cornering a soon-to-be-very-dead bunny in a drainpipe:


Anyway. Genocidal Maniac Hospital takes (let’s say) five emergency medicine residents per year and interviews one hundred per cycle. Like we talked about before, after interview season ends, GMH ranks all 100 applicants in order, from 1-100 in order of desirability. They will (presumably) end up with five applicants from this list.

The applicants do the same thing, but with every program where they interviewed. There are, obviously, way more applicants than spots, and it never works out on the first pass. There’s too much competition.

The algorithm starts with one round of matching based on the applicant’s lists, and continues until all spots are filled. The computer selects candidates to fill first basically at random. So let’s say that Rex, our first and randomly chosen applicant, just absolutely loved Tiller and ranked it #1. He gets placed in one of the slots at GMH.


After a bunch of candidates have been placed into their top choices, GMH’s slots are filled up:



The next candidate to come up is Fido. Fido also loved GMH, but all the spots are full with people who ranked GMH #1. The formula now has to check for fit; it does this by looking at the six candidates and removing the applicant who is lowest on GMH’s list. Let’s say Fido is rated higher by the program than Conan, but lower than Rex, Hodor, Ralph, and Wilson. This essentially means, “there are at least five people ahead of you, Conan, who are better fits with GMH,” and removes poor Conan from his tentative match at GMH.

The computer then essentially moves Conan’s #2 school, House of Pain, to the top spot and repeats the process.


At the conclusion of this – which, remember, happens for every applicant, in every specialty, at every program in the country – every applicant should be placed into their most preferred program except for:

  1. when those programs have been filled by applicants that the program itself prefers more; AND
  2. the applicants holding their slot do not have a more preferred match elsewhere when the previous rule is not satisfied.

There are, of course, programs that didn’t match just their top candidates, and applicants who didn’t get into their #1 place. But there should be zero scenarios where an applicant had a higher-rated program that also didn’t want them more than someone they got. That would be a Bad Match.

I know, it sounds complicated, but the guys that invented this won the Nobel Prize for it, so give me a break.

If you’re mathematically or logically-inclined, you might have noticed a necessary assumption here. The formula has to be weighted one way or the other; that is, it has to either optimize the Match for the applicant or for the program. This is because the algorithm can only make ‘ideal’ matches for a greater number of one set, not both.

The Match used to be program-weighted, but that changed after it emerged that some programs were lying to applicants about where they fell on the program’s rank list in order to improve their lot.

The nice thing about the Match is that the best strategy for matching (for an applicant) is to simply rank places in order of where you want to go. There is no benefit in trying to “game” the system by ranking somewhere else first. If your ideal program is something you think of as a “reach,” you should still rank it #1. If you end up not being able to match there – because the program has more-preferred applicants who also prefer the program – then the computer essentially treats your second choice as your new #1 and plugs you back in. There is zero downside to this strategy.

I bring this up because a couple of medical student friends think otherwise. In related news, they are getting Bad Advice, probably from other medical students. Faithful readers here are aware that the single worst source of advice about anything is… a medical student.

If you don’t match… well. That’s a subject for another post.

9 thoughts on “How The Match Works

  1. Seems logical. Makes sense. But then, I am worried about the source. You are, after all, a medical student, correct?

    Therein lies the dilemma.

  2. this is just so complicated! i love all your graphs and pictures to help us understand. finally, i finished the sympathizer-that was hard work. the language is amazing and the message: NOTHING IS MORE PRECIOUS THAN INDEPENDENCE AND FREEDOM. we know that. hope you have a great weekend. love,grandma

  3. Pingback: Tail of the Trail | STATUS HAZMATICUS

  4. Pingback: Helpful Posts | STATUS HAZMATICUS

  5. Pingback: The Fourth Year Lexicon | STATUS HAZMATICUS



  8. nice analogy. thanks for taking the time to dilute the seemingly complicated matching process. am looking to apply into obgyn in the near future.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s