Malek was born in Los Angeles, California, to Egyptian parents. He’s also of part-Greek descent. His father was a tour guide in Cairo. Malek has an identical twin brother named Sami; Rami is the older twin by four minutes. He also has an older sister. Malek attended Notre Dame High School in Sherman Oaks, California where he graduated in 1999 along with fellow actress Rachel Bilson. He received his Bachelor of Fine Arts degree in 2003 from the University of Evansville in Evansville, Indiana.

In 2004, Malek began his acting career with a guest-starring role on the TV series Gilmore Girls. That same year he worked voicing “additional characters” for the video game Halo 2, for which he was uncredited.[citation needed] In 2005, he got his Screen Actors Guild card for his work on the Steven Bochco war drama Over There, in which he appeared in two episodes. That same year, he appeared in an episode of Medium, and was cast as the prominent recurring role of Kenny, on the Fox comedy series The War at Home.

In 2006, Malek made his feature film debut as Pharaoh Ahkmenrah in the comedy Night at the Museum and reprised his role in the sequels Night at the Museum: Battle of the Smithsonian (2009) and Night at the Museum: Secret of the Tomb (2014). In the spring of 2007, he appeared on-stage as “Jamie” in the Vitality Productions theatrical presentation of Keith Bunin’s The Credeaux Canvas at the Elephant Theatre in Los Angeles.

In 2010, Malek returned to television in a recurring role as the Egyptian American suicide bomber Marcos Al-Zacar on the eighth season of the Fox series 24. Later that same year, he received critical acclaim for his portrayal of Corporal Merriell “Snafu” Shelton on the Emmy Award-winning HBO World War II mini-series The Pacific.

During filming of The Pacific, Malek met executive producer Tom Hanks, who was impressed with his performance and would later cast him as college student Steve Dibiasi in the feature film Larry Crowne, released in July 2011. In August 2010 it was announced that Malek had been cast as the Egyptian vampire Benjamin in The Twilight Saga: Breaking Dawn – Part 2.

Malek plays the lead role in the critically acclaimed USA Network computer-hacker psychological drama, Mr. Robot, which premiered on June 24, 2015. He was nominated for a Golden Globe Award, a Satellite Award, a Screen Actors Guild Award, and two Dorian Awards. He won a Critic’s Choice Television Award.

He appears as one of the main characters (Josh) in Until Dawn, a 2015 horror game released on the Playstation 4 on August 25. He lent his voice and was fully motion captured for the game.

Buster’s Mal Heart, the first movie in which Malek played a starring role, premiered in September 2016 at the Toronto International Film Festival to positive reviews. In it, Malek plays a man who leads two lives, one as Jonah and another as Buster. Casting him in the role before his success on Mr. Robot, the director, Sarah Adina Smith, said, “I had no idea how huge and adored he would become”. Reviewing the actor’s performance, John DeFore of The Hollywood Reporter wrote, “Fans of Mr. Robot won’t be disappointed in the least by this vehicle for Emmy-winning series star Rami Malek, which both fits in with Mr. Robot’s delusion-prone paranoia and lets the charismatic actor stretch out in his first feature lead”. Malek next starred as Louis Dega in Papillon, a remake of the 1973 film, co-starring Charlie Hunnam. It premiered at the 2017 Toronto International Film Festival, and had a limited box office release in August 2018. In 2017, Malek joined the cast of Bojack Horseman (season 4), voicing the character Flip McVicker, a writer who does not trust email.

In 2018, Malek portrayed Freddie Mercury in the Queen biopic, Bohemian Rhapsody. The film premiered in London on October 23, 2018, and became a major box office success, grossing over $900 million worldwide on a production budget of about $50 million. It became the sixth highest-grossing film of 2018 worldwide, and the highest-grossing musical biographical film of all-time. Despite mixed reviews for the film itself, Malek’s performance received critical acclaim. He won a Golden Globe for Best Actor in a Motion Picture Drama, the Screen Actors Guild Award for Outstanding Performance by a Male Actor in a Leading Role, the BAFTA Award for Best Actor in a Leading Role and the Academy Award for Best Actor for his performance in the film. To prepare for the role as Mercury, Malek moved to London where he employed a dialect coach and movement coach, and took piano and singing lessons. For four hours each day, he studied videos of Mercury with his movement coach, Polly Bennett. This included watching the 1985 Live Aid concert video on YouTube at least 1,500 times to perfect his performance for the movie. He also had to get used to singing and speaking with a set of false teeth that mimicked the singer’s overbite. Brian May, Queen’s guitarist who often attended filming, is quoted as saying that Malek’s performance was so accurate that “we sometimes forgot he was Rami”. Malek considers his performance as Mercury the most important in his career, saying:

This is a role I don’t think can be outdone. I think we’re always searching for that next great role, and I guess I’m fortunate that I’ve already been met with it. I’d like to think that there is more out there for me to do, and there is, but I do doubt that there is anything that lives up to how precious this role and this human being have been in my life.

During the press tour for Bohemian Rhapsody, Malek said he is working on a movie, one he plans to write, direct, and produce himself on a small budget, since it is a story that he says “might get passed on by studios looking for something a bit more broad and commercial”. In December 2018, it was announced that Malek would produce and star in an eight-episode podcast called Blackout. Scott Conroy is the writer of the upcoming podcast, a thriller about a small-town radio DJ who must “fight to protect his family and community from a coordinated attack that destroys the power grid and upends modern civilization”. The podcast debuted with two episodes on March 19, 2019, with six subsequent episodes premiering weekly. On April 25, 2019, Malek was confirmed as the villain in No Time to Die, which has a release date of April 2020.