RICKY GERVAIS (U.K. Office writer and co-creator and “David Brent”): When we were pitching our version of The Office to [BBC producer] Jon Plowman, he said, “I’ve got one question. This guy who’s the boss, if he’s so terrible at his job, how does he keep it?” and I said, “Let’s take a little walk around the BBC, shall we?”

STEPHEN MERCHANT (U.K. Office show-runner): The Office was a quirky show even in the U.K. The idea that this weird, downbeat sitcom … would somehow translate to American television, where everyone was supposed to be beautiful and a winner, was hard to fathom.

GREG DANIELS (U.S. Office show-runner): Ricky and Stephen had created something amazing, and I wanted to figure it out. But I didn’t really think it was plausible that it would come to American TV or that I would get the job. I just wanted to meet them and ask them about it.

Rainn Wilson as a particularly feisty Dwight Schrute in The Office’s “Livin’ the Dream” episode.

GREG DANIELS: It turned out that, number one, [Gervais and Merchant] loved The Simpsons. Number two, Ricky’s favorite Simpsons episode was one I’d written called “Homer Badman.” [The 1994 episode involved Homer being accused of sexual harassment after he retrieves a gummy Venus de Milo stuck to a babysitter’s butt.]:

Lisa: Dad, I don’t understand. What is she saying you did?

Homer: Well, Lisa, remember that postcard Grampa sent us from Florida of that alligator biting that woman’s bottom?

Bart: Oh yeah, that was brilliant!

Homer: That’s right, we all thought it was hilarious. But it turns out we were wrong: that alligator was sexually harassing that woman.

RICKY GERVAIS: We met with a lot of amazing show-runners from some of my favorite programs of all time. We chose Greg not just because of his body of work, which was as good as anyone’s, or because he was a nice chap. It was because he was the only one that brought up that he thought it was a love story.

STEPHEN MERCHANT: That was the thing that you really need to get right. People tuned in for the David Brent/Michael Scott character, but they stayed for the love affair.

BEN SILVERMAN (executive producer):I went to Les Moonves [the C.E.O. of CBS], he passed. Gail Berman [president of entertainment for Fox], she passed immediately. Didn’t get it. HBO said, “We’ll never do a remake of a show.” Showtime wasn’t doing shows like this.

NBC eventually signed on for the pilot, and Ben Silverman and Greg Daniels set about creating the U.S. Office. It remained a single-camera faux documentary, and, like the U.K. Office, they set it in a gloomy office park.

They found a perfect backdrop in an old coal-mining city that was a little past its prime: Scranton, Pennsylvania.

GREG DANIELS: I wanted a place that was just outside of the city but nobody in New York ever visited. A place that was a little faded. There’s something about the Northeast that feels like England to me in a lot of ways. With the weather, it’s a little harder to live there. The people just seemed like they might be hiding their emotions somehow.

Jenna Fischer, playing Pam Beesly, commiserates with the camera in the “Chair Model” episode.

I was reading John O’Hara, the short-story writer, and he has a lot of stuff set in Scranton. I had a list of tons of cities that I thought would work, like Nashua [New Hampshire] and Yonkers [New York], but Scranton is a comedy word. It’s got that hard K sound. Scraaaan-ton.

STEPHEN MERCHANT: It seemed sensible to me that if they could rewire The Office at all, it would just be to maybe downplay some of those more cynical, sour British elements and dial up more of that American can-do bright optimism, without losing the fundamental DNA of what made the show work.

The First Hire

GREG DANIELS: The first person I hired for anything on The Office was B. J. Novak. He was a writer-performer hire. Writer-performers were great on S.N.L. when I was a writer [between 1987 and 1990]. And also, one of my favorite shows growing up was Monty Python’s Flying Circus, and they’re all writer-performers.

I saw B.J. do stand-up, and he made a joke about not learning much in college ’cause he had a double major, psychology and reverse psychology. I was like, “Wow, that’s a damn good joke.”

JENNA FISCHER (“Pam Beesly”): Before The Office? I was a struggling actress. I was auditioning for anything and everything I could. I had done a pilot called Rubbing Charlie. That’s real.

RAINN WILSON (“Dwight Schrute”): I did theater for about 10 years in New York before I did any TV or film. [Then] it was a lot of struggling and toiling around, doing little guest spots on TV shows. In C.S.I. I was Creepy Guy in Supermarket.

OSCAR NUNEZ (“Oscar Martinez”): I was auditioning stuff, but my day jobs were catering and babysitting.

ANGELA KINSEY (“Angela Martin”): I was working at the ImprovOlympic, iO West, an improv-comedy theater in Los Angeles. I helped run the training center and performed there any time they’d give me stage time. I was in a show with Kate Flannery, who ended up playing Meredith on The Office. The name of our show was Girl Team Balls.

The mug that says it all.

Enter Angela

GREG DANIELS: When I did King of the Hill, we were in an office building and surrounded by office culture. I’d hear stuff on the elevators all the time. Like once, I heard this woman in the elevator say something like, “I don’t want to be a bitch, but …” I thought, well, that’s a good character. And that became Angela.

Enter Phyllis … and Jim, and Pam …

PHYLLIS SMITH (“Phyllis Vance”): I was working as a receptionist in an aerospace-defense company in Sherman Oaks. A friend of mine who worked for Stu Billett Productions called and said, “Phyllis, they need a mousy woman for a court show.” I really didn’t want to, but I had one hour for lunch, so I drove over the hill [into the San Fernando Valley] to do this audition.

“If they could rewire The Office at all, it would just be to maybe downplay some of those more cynical, sour British elements and dial up more of that American can-do bright optimism.”

CREED BRATTON (the one and the same): I did a bunch of stuff before The Office. John Crosby, the famous agent, saw me in a play with Beau Bridges, and I had my hair and I was very, very confident. So he signed me and I didn’t have to go out or anything. He just said, “You got a job over here.”

JOHN KRASINSKI (“Jim Halpert”): While I was in the waiting room at 30 Rock, six Jims that looked identical to me went in and did their auditions, and when they left they were high-fiving each other.

Someone sat down across from me with a salad and said, “You nervous?,” and I said, “No, you know, you either get these things or you don’t. But I’m terrified for the person creating the show because, I mean, I just feel like Americans have such a track record of taking brilliant shows and ruining them.” And he goes, “I’ll try not to. My name’s Greg Daniels.”

JENNA FISCHER: I remember the three other Pams so vividly. There was this one Pam who had on knee-high leather boots and I was so judgmental. I was like, “Oh, honey, Pam would never wear boots like that.”

GREG DANIELS: Jenna came in and kind of blew my mind, because I didn’t understand it. I was like, she doesn’t appear to be acting. She appears to simply be Pam.

JENNA FISCHER: My take on it was this girl Pam was being forced by her insane boss, Michael, to be part of a documentary that she cared nothing about…. So I thought, O.K., if that is my circumstance, what would I do in this real situation?

John Krasinski’s Jim Halpert and Ed Helms’s Andy Bernard reminisce in the “Andy’s Ancestry” episode.

So Greg starts this interview with me and he says, “Pam, do you like being a receptionist here at Dunder Mifflin?” and I just said, “No.” That’s it. That’s all I said…. He waited for me to say more and I didn’t and I just sat there, and then he started laughing and then he kept asking me more questions. I thought, “He’s either going to love this or hate it, right?”

JOHN KRASINSKI: I know it sounds like a fairy tale, but I remember Jenna walking in, and as soon as she crossed the threshold on the door, I was like, “Well, that’s it. That is exactly who should play Pam. I hope she can put two words together because she has the part.”

RAINN WILSON: On that first audition, I auditioned for both Michael and Dwight. And my Michael was just terrible.

GREG DANIELS: I remember taping myself on a video camera late at night, doing the sides for Michael. ’Cause I was like, I don’t even know what to tell them, you know? I did it a bunch of times, and I realized that one of the keys for people trying out for Michael was that he’s thinking that if he does a good job on this documentary, maybe Jennifer Aniston will watch it. That’s in the back of his head.

BEN SILVERMAN: Our immediate short list for the Michael Scott character was Bob Odenkirk. But then I get a call from Stacey Snider, who’s the head of Universal Pictures, NBC’s sister studio. She calls me on the lot and says, What about Steve Carell for the lead?

STEVE CARELL (“Michael Scott”): I remember, before I auditioned, I was talking to Paul Rudd. I’d never seen the original Office and he asked what I was up to. I told him I was going to audition for the American version of The Office and he said, “Ugh, don’t do it. Bad, bad move. I mean, it’s never going to be as good.”

KATE FLANNERY (“Meredith Palmer”): I remember they said no makeup. Usually when they say no makeup, they mean lip gloss and some mascara. But it was like, “No, no, no, take it off, take it off, take off the lashes.”

BRIAN BAUMGARTNER (“Kevin Malone”): Do you remember what they told you about Meredith?

KATE FLANNERY: They just said she was lactose intolerant, divorced, and had a hysterectomy. Go!

Documentary-Style

GREG DANIELS: One of my theories was that the show had to be handmade. It couldn’t be a factory product. What I didn’t like about network television was how much of a factory it was. The writers wrote jokes and the jokes got passed down to the actors and they didn’t overlap much.

Dwight surveys the scene.

JENNA FISCHER: Everyone in the cast had to be hair-and-makeup ready and at their desks starting at 7:30 A.M., and we would “work” for 30 minutes. Ken would walk around with just a camera operator and a boom and record us, just B-roll of us at our desks.

KEN KWAPIS (director): We started each day shooting basically documentary footage of the whole cast, the entire ensemble, just pretending to work.

BRIAN BAUMGARTNER: Ken and Greg had devised a little scheme. For many pilots, everything feels very new because it is new. You’re starting a new show and you’re in a new environment. Greg wanted the office to feel lived in.

JENNA FISCHER: I remember sitting there that first day and thinking, What am I supposed to do?

BRIAN BAUMGARTNER: The computers didn’t work yet. I don’t think they got plugged in until the pilot.

JOHN KRASINSKI: It was like an acting exercise. I remember being like, “Oh, this is so nerdy.” But by the end of it, we were all kinda into it. We were dialed in.

KEN KWAPIS: I think everyone sort of just figured out what their jobs are at a paper company. It started to create a sense of what their normal day is like.

The Right Cut

GREG DANIELS: In the edit room, which lasted forever, we did 23 cuts. I ended up losing a bunch of stuff, like the thing with Michael’s testicles. [In a deleted scene, Michael tells Pam that he thought he found a lump in his testicles that morning but it turned out to be nothing, and then he awkwardly changes the subject to Pam’s smoked-turkey sandwich.] But there were some good things that got added, like Michael’s WORLD’S GREATEST BOSS mug that he bought from Spencer’s Gifts.

KEN KWAPIS: One of the reasons I was so happy with how Greg cut the pilot is he didn’t cut it for tempo. Or in other words, he didn’t make it more up-tempo. It still had weird pauses, where if it was any other television show, they’d either add canned laughter or three more jokes in that space. Or music. There’s nothing, no music or anything. If it ever aired, it’d be the driest show on a broadcast network.

Director J. J. Abrams and Steve Carell discuss the “Cocktails” episode.

The pilot was screened for NBC employees in early May 2004. They gave it a score between 0 and 10.

KEVIN REILLY (president of prime-time development at NBC): Every room was giving it a 1 or a 0.5.

BEN SILVERMAN: I get a call from NBC that the testing came in and it’s horrible. And I’m like, “You’re testing this next to old Friends episodes.”

GREG DANIELS: I knew we weren’t going to test well. Everything that I liked never tested well. The Mary Tyler Moore Show didn’t test well. Cheers didn’t test well. Seinfeld didn’t test well. [Jerry Seinfeld and Larry David actually had the framed test-screening letter hung above a toilet. “We thought if someone goes in to use this bathroom, this is something they should see,” Seinfeld told TV Guide. “It fits that moment.”] The Office is firmly in the pattern of Mary Tyler Moore and Cheers and Seinfeld.

The testing was so bad that the media reported on it. “America Remakes The Office, but No One’s Laughing,” announced a Guardian headline. ”Office Gossip: It’s a Downer,” wrote the New York Post.

KEVIN REILLY: Nobody liked it. Except one room. [At NBC, a special screening room had been set up just for the assistants and associates. In other words, the young people.] It was the only room I was interested in. There were like 40 people in there. I went in and said, “What do you guys think?,” and they told me, “Not only is this the best thing we’ve done, it’s the only thing we’d watch that’s currently on the air.” That’s all I needed to know.

A typical season for a network show is 22 episodes, though sometimes a new and unproven show will get 13 episodes at first. The Office got six. On March 24, 2005, the pilot premiered. It was sandwiched between ratings juggernauts The Apprentice and ER.

Out with … Less Than a Bang

GREG DANIELS: Pretty much everything I like or have worked on is character comedy. If you’re going to go with character comedy, the audience has to learn who these characters are, right? And that takes time. They don’t start with a bang usually. So I wasn’t thrown or worried when we started slow.

Kate Flannery as Meredith Palmer, grabbing something like her fifth drink in the “Moroccan Christmas” episode.

New York Daily News: “So diluted there’s little left but muddy water.” USA Today: “A passable imitation of a miles-better BBC original.”

The Critics Let Loose

BRIAN BAUMGARTNER: My favorite review is from a gentleman by the name of David Bianculli [a TV critic on NPR’s Fresh Air]. The way he took us down, it was like dark poetry. [Bianculli (from 2005): “As fights for independence from England go, it hardly ranks up there with the American Revolution … Where Ricky Gervais let the boss’s insecurities show through, Steve Carell is all noise and stupidity. He’s like a sketch comedy character, not a real person. Not just foolish but a fool.”]

STEVE CARELL: It was a remake of a very heralded show, and it did not get good reviews out of the blocks.

The pilot was viewed by 11.2 million people, but by the end of The Office’s six-episode first season, that number had dropped by more than half, to just 4.8 million, according to Nielsen. The conventional wisdom was that it wouldn’t be back for a second season.

GREG DANIELS: I made a lot of Seinfeld comparisons in the beginning. I was like, “Look how small that started. It’s something new, it’s something unique, it’s funny, let it grow.” But it turns out every single producer made Seinfeld comparisons if you had a show that was struggling. No matter how good it was or how close it was to Seinfeld, they’d heard that argument before. They were like, “Well, if it’s really like Seinfeld, Seinfeld only had four episodes or whatever in the first season.”

MIKE SCHUR (writer and “Mose Schrute”): Kevin Reilly basically staked his entire professional reputation on The Office.

“Les Moonves [C.E.O. of PBS], he passed. Gail Berman [president of entertainment for Fox], she passed immediately. Didn’t get it. HBO said, ‘We’ll never do a remake of a show.’”

KEVIN REILLY: Picking it up the first year took some finesse, but nothing like the challenge of bringing it back. I think everyone thought, “O.K., you had your shot with this little thing. We’re moving on, aren’t we?”

BRIAN BAUMGARTNER: How did you get it revived?

KEVIN REILLY: That was brutal. It was one of the toughest things in my career. I’d realized, at this point, odds are I’m going to get fired. I kept ordering it, and I had crazy meetings where the head of finance would come in and I’d go down the list of the things we’re ordering…. I’d ask, “Where’s The Office?” It was this woman, Diane. She said, “Oh, you should talk to Jeff.” Meaning Jeff Zucker, who’s running the network at the time.

So I called him and said, “Jeff, where’s The Office?” And he’s like, “No, no, we’re definitely ordering it.” But it’s not in the tally sheet, and we’re locking the numbers. “Let me talk to Diane.” I come back in and there’s four. “Diane, why are there four episodes of The Office?” “Did you talk to Jeff?” I went through this 19 times. Eventually, I don’t know, we just got there.

Andy gets pissed in the “Promos” episode.

A Certain Kind of Humor

ED HELMS (“Andy Bernard”): For some reason, our generation embraced the comedy of failure and awkwardness and poor communication. My parents never got The Office. They were mortified by it, all of the awkwardness and the tension that we think is so funny.

PAUL FEIG (executive producer and director of The Office’s biggest episodes, including “Office Olympics,” “Halloween,” and “Dinner Party”): To me, the most awful, embarrassing moments in your life are so hellish when you’re going through them, but to watch somebody else go through the same thing is so liberating.

EMILY VANDERWERFF (TV critic for Vox): Really this tradition comes from the Brits. Fawlty Towers is a show that kind of plays in that vein. And people didn’t really want to see that on American television in the 80s. Seinfeld is a big breakthrough for a show that had cringe elements. [From the 1998 Seinfeld episode “The Wizard”]:

Elaine [to the Black waitress]: Long day?

Waitress: Yeah, I just worked a triple shift.

Elaine: I hear ya, sister.

Waitress: Sister?

Elaine: Yeah. It’s okay, my boyfriend’s Black.

EMILY VANDERWERFF: The British Office is the big breakthrough for what we think of as modern cringe comedy.

RICKY GERVAIS: David Brent wanted to be a philosopher and a teacher. He wanted to be cool. He wanted to be sexy. He wanted to be funny. He wanted to be all those things that he wasn’t quite, and that is comedy at its most basic, particularly in a sitcom.

A sitcom is about an average guy or gal trying to do something that they’re not equipped to do. That’s what we’re laughing at, the blind spot. So I just made David Brent all about the blind spot.

Dwight and Michael in the “Gay Witch Hunt” episode.

EMILY VANDERWERFF: Michael Scott came out of a culture where … we still had a lot of comedians who were deliberately thumbing their nose at societal conventions, who were saying, “This is bad, and we should say that.” Michael Scott is trying to be that kind of comedian and utterly failing at it. And that’s the joke about him.

Like when Michael replaces his girlfriend’s ex-husband with himself in a family photo:

Michael: That is my Christmas card. It’s a picture of you and me and your kids on a ski trip, having a blast. Ski-son’s greetings.

Carol: No, see, we never went on a ski trip.

Michael: I know, I know.

Carol: I went on a ski trip, two years ago, with my kids and my ex-husband.

Or when Michael insists on hoisting a new, larger employee onto a conference table as part of a welcoming ceremony:

Michael: Bend at the knees. Okay. Here we go! Here we go! I’m under this. I’m under this hock here. I don’t know what I’m grabbing here!

Or when Michael, under oath during a deposition for Jan’s lawsuit against the company, describes his girlfriend’s … assets:

Jan’s lawyer: Did Ms. Levinson ever say why she thought she was being fired?

Michael: She thought it had to do with the twins. That’s what I call them.

Jan’s lawyer: Can you be more specific? Who are the twins?

Michael: Um, to be delicate, they hang off milady’s chest. They make milk.

EMILY VANDERWERFF: You’ll sometimes see people talk about homophobic jokes on Friends. You don’t really get that with The Office. When Michael Scott says something homophobic, the joke is on him in a way that has allowed the show to sustain itself in this era of people being more aware of the harm that kind of humor can do.

RICKY GERVAIS: It’s important that people know the difference between the subject of a joke and the actual target. The target was actually people pretending to be all those good things, but not quite getting it right. We were taking a stab at this false notion of pretending to be about equality and fairness, but getting it wrong.

Adapted from Welcome to Dunder Mifflin: The Ultimate Oral History of the Office, by Brian Baumgartner and Ben Silverman, to be published by Custom House on November 16