While Dwight is Michael’s right-hand man and he believes Ryan to be like a son to him (although the feeling isn’t mutual), Jim Halpert has been Michael Scott’s protégé since the beginning of The Office. In the show’s very first scene, Michael calls Jim into his office to give him sales advice, right before Jim told the camera that he doesn’t really care about his job.

RELATED: The Office: 10 Episodes That'll Never Get Old

In the 200-odd episodes that followed, Michael and Jim’s friendship went through various different stages. At one point, they butted heads as the co-managers of the Scranton branch. These are the best episodes of The Office that explore Michael and Jim’s dynamic.

Murder (Season 6, Episode 10)

Andy and Michael in a standoff in The Office

When the Wall Street Journal reports that Dunder Mifflin is in trouble and everybody worries that they might be losing their jobs, Jim just wants to get on with the day like everything’s normal, but Michael can see that won’t work.

Instead, Michael distracts the office with a murder mystery board game. Jim begs Michael to call off the game throughout the episode until Michael finally snaps and tells Jim, “Shut up! They need this game, Jim. Let us have this stupid little game, all right?”

Office Olympics (Season 2, Episode 3)

Michael, Jim, and Dwight at the office Olympics

For the most part, season 2’s “Office Olympics” is a Michael and Dwight episode as Michael brings the assistant to the regional manager to help close the sale on his condo. In Michael’s absence, Jim throws a small-scale Olympics around the office.

But it leads to Michael and Jim’s first great bonding moment at the end of the episode. Michael is worried he’s made a huge mistake buying his condo, so Jim lifts his spirits by giving him the gold medal.

The Manager And The Salesman (Season 6, Episode 16)

Michael and Jim in the conference room in The Office

When Sabre acquires Dunder Mifflin and Jo Bennett becomes the new CEO, she doesn’t like the idea of co-managers implemented by David Wallace and asks either Michael or Jim to step down and join the sales team.

Initially, Michael is excited to be a full manager again but changes his mind when he learns that Sabre has no commission cap on sales and Jim stands to earn more as a salesman than a manager.

The Promotion (Season 6, Episode 3)

Michael and Jim as comanagers in The Office.

The office adjusts to Michael and Jim being co-managers in the season 6 episode “The Promotion.” They face their first major conflict when they have to decide who to give raises to because there’s not enough extra cash for everybody. Their employees turn against them when they learn that they’ve been judging their merits by placing jelly beans on old pictures of them.

RELATED: 10 Actors Who Were Considered For Roles In The Office

Despite clashing throughout the episode, Michael and Jim have a sweet moment in the end when Michael tells Jim that he’s glad he has someone to share this unenviable part of the job with.

Email Surveillance (Season 2, Episode 9)

Michael and Jim singing Islands in the Stream in The Office

Jim invites everyone in the office except Michael to a barbecue in season 2’s “Email Surveillance.” He thinks his co-workers will be on edge if their boss is at the party. Unfortunately, this is around the time that Dunder Mifflin’s I.T. department gives Michael access to his employees’ emails, so he sees all the Evites.

After being similarly shunned by his improv classmates, Michael crashes the barbecue and starts singing “Islands in the Stream” on the karaoke machine to a blank-faced audience. Jim sweetly steps in to complete the duet.

Booze Cruise (Season 2, Episode 11)

Michael and Jim on the booze cruise in The Office

Jim tells Michael about his crush on Pam during the titular seabound voyage in season 2’s “Booze Cruise.” Despite his typically inept behavior throughout the episode, Michael has some surprisingly sage advice for Jim.

Michael tells Jim, “If you like her so much, don’t give up.” Jim says, “She’s engaged,” but Michael counters, “BFD, engaged ain’t married. Never, ever, ever give up.” And, of course, Jim never does.

Launch Party (Season 4, Episodes 5/6)

Michael at the Dunder Mifflin Infinity launch party in The Office

Ryan launches the Dunder Mifflin Infinity website that ultimately lands him in jail for fraud in the season 4 two-parter “Launch Party.” Michael believes he’s invited to the party and invites Jim to drive all the way to New York to attend it with him.

However, when they get into the city, Jim realizes that Michael has been given an invitation to an online chatroom — not an exclusive nightclub with a password, as Michael had assumed.

Koi Pond (Season 6, Episode 8)

Michael falls in a koi pond in The Office

Michael and Jim go out on a sales call in season 6’s “Koi Pond,” and when they get back, Michael is soaking wet. He claims they got caught in some flash rain, but Jim is dry and the office they visited calls to say that Michael owes them money for a koi he stepped on when he fell in the pond in their lobby.

RELATED: The Office: The 10 Best Episodes After Michael Left

The rest of the office makes fun of Michael throughout the day, and Jim keeps trying to stop everyone from making jokes. When Meredith’s friend swipes the security footage, they find out why — Jim let Michael fall in because he felt patronized by him.

The Secret (Season 2, Episode 13)

Michael and Jim at Hooters in The Office

After the events of “Booze Cruise,” Michael knows that Jim likes Pam in season 2’s “The Secret.” Since Michael is terrible at keeping secrets, Jim is petrified that he’ll give it away.

He even ends up having lunch with Michael at Hooters and putting up with his awkward pun-making just to keep him from revealing the secret. And then he ends up giving it away anyway.

Goodbye, Michael (Season 7, Episode 22)

Jim says goodbye to Michael in The Office

Michael has sweet moments with a bunch of other characters in his season 7 swansong “Goodbye, Michael,” from his paintball fight with Dwight to his silent last words to Pam, but the episode’s crowning tearjerker moment is Jim’s goodbye.

Jim figures out that Michael lied about when he was leaving and that he’s actually leaving a day early. They decide to save the real goodbyes for “lunch tomorrow,” but a teary-eyed Jim tells Michael he’s the “best boss I ever had.”

NEXT: The Office: 10 Best Michael & Dwight Episodes