Primetime Emmy nominee Peter Kosminsky is returning to television for the espionage thriller The Undeclared War. The series centers on a group of British intelligence agents as they try to find the source behind a seeming Russian hacker campaign to upend the country's general election.

Hannah Khalique-Brown leads the cast of The Undeclared War as Saara, a young coding prodigy who finds herself the center of the counterintelligence campaign as she discovers the secrets of the hack within its code. Alongside her is Simon Pegg, Mark Rylance, Maisie Richardson-Sellers, Edward Holcroft, Adrian Lester, Alex Jennings, Kerry Godliman and German Segal.

Related: Simon Pegg's 10 Best Movies, According To Rotten Tomatoes

In anticipation of the show's Peacock streaming premiere, Screen Rant spoke exclusively with star Simon Pegg to discuss The Undeclared War, Mission: Impossible comparisons, his recent return to television, and more.

Simon Pegg The Undeclared War

Screen Rant: Very excited to talk about The Undeclared War. I did not know what to expect going in and I was hooked from start to finish. What was it about the show that really caught your attention and made you want to be a part of it?

Simon Pegg: Well, two things really. Firstly, it was Peter Kosminsky. As a writer and a director, he's sort of legendary in British television. He's created some of the most important and memorable dramas of recent years, and to get something from him is an immediate, "Okay, wow."

Then I read the screenplay and devoured it, all six episodes in one go, because it just drew me in so quickly. I knew I was gonna say yes before I read it, but by the time I'd read it, I was fizzing with excitement. Not least because it was the kind of role that people tend not to offer me, just because they assume that I do one thing and one thing only. It was, for many reasons, a big thumbs up from me.

On that note, many general audiences at this point know you a lot for Benji in the Mission: Impossible movies, which has the technobabble. But he's more comedic, whereas this is a much more serious part. What is that like for you going from those two different ranges, while still being in a somewhat similar field?

Simon Pegg: It was great. It was a really wonderful opportunity to get to flex some different muscles and to do something which perhaps wasn't expected of me. It was funny to me at times, because I'd occasionally say phrases that I would say, or terms that I would use, as Benji, like "air gapped." I think I'd used that term weeks before when I was shooting Mission, and then suddenly I was saying it again and was like, "Oh, wow, there's some parallels here."

But Danny is a real world character, and he's planted in a far more likely reality than the pure entertainment of Mission: Impossible; that's a very heightened world. Danny is a real person, or at least based on the kind of person that would be there, and that came with a certain amount of responsibility and challenge.

That actually leads to my next question. What would you say were some of your biggest creative challenges in getting to the heart of Danny?

Simon Pegg: I think when I read it, the way Danny speaks. He's so fluent in coding language; in political language. He's so many things, and he's so good at all of them that I wanted to make sure that when I played Danny, that came across. So, I learned my lines weeks in advance. I would take a scene, I looked at the schedule and I'd learned the scenes very far in advance, and I would just go over them.

Something that Anthony Hopkins once said about, "You learn and learn and you do the scene until you forget that you've remembered it," and I wanted to get to that point when it just flowed out of me, all this kind of quite complex dialogue, just felt very naturalistic and real. That, for me, was such a pleasure, because it took some work and I like working.

Simon Pegg as Danny in The Undeclared War

And you're a very busy guy. I was just talking to Hannah and she was telling me how she did weeks of coding to prepare for her role. Did you do any similar kind of studying, or was it just, like you were saying, memorizing the script?

Simon Pegg: Well, the great thing about Peter is that he is incredibly sympathetic towards his actors and the process of acting and Peter actually had an entire life history of Danny, which he gave me, which was like two sides of A4 [paper] explaining his childhood through foster care, how he became a rugby player, his family, his wife, his two sons, this whole background, which felt — I'm not a method actor, I believe that acting is pretending and you just imagine what you're gonna pretend and you do it.

But sometimes it really does help to have that kind of knowledge in your head when you're playing a character, because you feel more three-dimensional. You're not just putting on a mask, you're actually playing something a little bit more substantial. For me, it was more about getting to grips with Danny as a person, as opposed to what his job was.

I think for Hannah, because Hannah plays Saara, this incredibly prodigious coding genius, she wanted to have that same kind of sense of ease with what she was doing, but that is so much part of who she is. Whereas Danny is like a father to all of those people at GCHQ, when he's in Whitehall, he's a politician of sorts, and it was more about getting in tune with those moments.

You do have that unique dynamic with Saara, as well as a few other characters. What was it like developing your rapport with your other actors?

Simon Pegg: Getting to work with someone like Alex Jennings, who I have most of my scenes with; he plays David Neal, my sort of immediate superior who I go to Whitehall with and sit in the Cobra room with. He's such an incredible actor. He's someone that I've always admired, he's one of those people that has been in so much, but has managed to avoid being a celebrity. It's kind of the actor's dream, and to get to work with him was an absolute joy. And Adrian Lester, and everybody.

With Danny, he has those different relationships. He has an incredibly close friendship with David, and then you've got Ed Stoppard, who's playing the kind of hawkish Toria, who's just always at him at the Cobra table. That relationship was really good fun. Or with Hattie [Morahan], who plays the secretary of the Foreign Minister, I think, the one who gets framed. They've got a very easy friendship; it's a little flirty, but there's no sense that there's anything going on there.

All that stuff was all really kind of just micro details, which Peter puts into it, which makes it all feel very real.

Mark Rylance in The Undeclared War

I was a little disappointed to see that you and Mark Rylance didn't get to share any screen time, as I enjoyed you two together in Ready Player One. What was that like for you when you heard Mark would be a part of The Undeclared War, but that you weren't going to be sharing any time together on screen?

Simon Pegg: It was a combination of disappointment and relief. Disappointment because I love Mark, and I love getting to act with him; it's obviously a privilege. But also for that reason acting with him is hard, because you have to absolutely do the very best you can possibly do, because otherwise you'll just disappear from the screen. He is such a magnetic actor and such a watchable presence that if you're in a scene with him, you have to fight for your f-----g life. [Laughs] That's not him grandstanding, that's not him trying to outdo you or anything, he is just so gifted that it's nerve wracking.

But no, I was obviously sad, because I love him. He's a brilliant guy, and you want to act with the best people in your career. I felt very lucky in this with Alex and with Adrian, but also with someone like Hannah, who was brand new and just stepped on set with all the confidence of a very established actor. She's incredible.

Yeah, she did a phenomenal job leading the series, especially given it was one of her first roles. One thing I love about this show is that it closes on a note where it could not come back, or it could come back for more. Have you heard or did you talk with Peter at all about whether he had ideas for more?

Simon Pegg: Yeah, I mean, I think obviously, when you're really enjoying a show, you always tend to kind of start to talk about, "Oh, could we do more of this kind of thing?" I think Peter definitely has ideas, he's mentioned that. All these things always depend on economics and on all the kind of boring stuff that shouldn't really matter.

But I think if things go well for the show—it's certainly done well here in the UK—then there's a good possibility we'd do more. I'd love to, it was a really fun job and it felt very special to be part of it, so yeah, I'd love to do more.

The Undeclared War Simon Pegg

Well, hopefully, we get to hear more from you on that front. Before we go, the past few years have seen you return to television, what with Truth Seekers and a few other shows, while you're still also doing feature-length projects. What's that been like for you coming back to where you first started with Spaced while still also exploring these blockbuster realms?

Simon Pegg: It's a very privileged time, I think, for actors. Because it's no longer the case that there are TV actors and film actors. TV is no longer the poor cousin of cinema, TV has evolved into something incredibly vital and an amazing platform for telling longer stories on a similar cinematic scale to what you see in the movies.

It was interesting to come back to Channel 4 here in the UK, which is where The Undeclared War aired, because the last thing I did on Channel 4 was Spaced. It was a real kind of coming home for me, and things have changed a lot since then, just in terms of scope and credibility. In a way, it was kind of easy. It feels two sides of the same coin now.

The Undeclared War Synopsis

Simon Pegg in The Undeclared War

Set in 2024 in the run up to a British general election, THE UNDECLARED WAR tracks a leading team of analysts buried in the heart of GCHQ, the UK’s version of the NSA, secretly working to ward off a cyber-attack on the country’s electoral system.

The cast includes Academy Award winner Mark Rylance (“Wolf Hall,” “Bridge of Spies”), Simon Pegg (“Star Trek,” “Mission Impossible”), Adrian Lester (“Riviera,” “Mary Queen of Scots”), Alex Jennings (“A Very English Scandal,” “The Crown”), Maisie Richardson-Sellers (“Star Wars: The Force Awakens”) and exciting newcomer Hannah Khalique-Brown.

THE UNDECLARED WAR is co-produced by Playground and NBCUniversal International Studios, a division of Universal Studio Group. Peter Kosminsky will executive produce alongside Colin Callender (“Wolf Hall”, “All Creatures Great and Small”) and Noëlette Buckley (“Wolf Hall”, “King Lear”) for Playground. Robert Jones (“Babylon”) is the Producer. NBCUniversal Global Distribution is handling international sales.

Check out our other interview with The Undeclared War star Hannah Khalique-Brown.

The Undeclared War is now available to stream on Peacock.