A Pepsi-funded movie based on a soda commercial character just took $15.5 million on its opening weekend

Baron Davis, J.B. Smoove and Kyrie Irving on set at Pepsi's Uncle Drew commercial filming in Miami, Florida in 2015
Rodrigo Valera | Getty Images

A movie created by Pepsi about the star of one of its commercials has just taken $15.5 million at the box office on the first weekend of its theatrical release in the U.S.

“Uncle Drew” is a feature film starring Boston Celtic basketball player Kyrie Irving (main picture, right), based on a character of the same name who first appeared on the small screen in a 2012 series of ads for Pepsi Max.

The movie is a collaboration between Pepsi Productions and movie studio Lionsgate, with production company Temple Hill, and was the second-highest new release of the weekend after action movie “Sicario: Day of the Soldado,” which took $19 million and stars Josh Brolin and Benicio Del Toro.

The original “Uncle Drew” commercial featured an elderly man, played by Irving in prosthetics, watching his nephew playing basketball. Irving substitutes for an injured player, shooting hoops to the astonishment of his teammates, before a flashback shows his transformation. The ad ends with the Pepsi Max logo and the line “A zero-calorie cola in disguise.”

The first ad in the series went viral and has been watched more than 50 million times on YouTube, with the whole run of ads getting more than 100 million views online, according to Pepsi in an online statement.

Businesses have been increasing their spending on so-called branded content, or films and articles that look more like editorial content than advertising, aiming to entertain people in a world where ad blockers have been downloaded by millions.

Pepsi’s movie is not the first time businesses have worked with the film industry — in 2014, a Bombay Sapphire-backed short film called “Room 8” won a British Academy of Film and Television Arts (BAFTA) award, part of the gin brand’s Imagination Series created with Oscar-winning writer Geoffrey Fletcher, and the movie was also screened at New York’s Tribeca Film Festival in 2013.

Boston Celtic basketball player Kyrie Irving in New York City in June 2018
Mike Pont | Getty Images

PepsiCo will also be hoping the movie helps to shift more cans of soda. Pepsi's beverage business, which is its largest and includes brands like Gatorade and its namesake cola, has been struggling to contend with increased competition from and changing consumer tastes. In April, Chief Financial Officer Hugh Johnston told investors the company will be to reinvigorate its North American beverage business, after the company reported organic sales for its drinks unit were down 2 percent.

“Bringing ‘Uncle Drew’ to the big screen has been such a pleasure for us,” said Aziel Rivers, director of Pepsi Marketing in a statement posted online ahead of the movie’s release. “Since its inception, ‘Uncle Drew’ has been a hit with our consumers and basketball fans alike, and we're excited to continue our relationship with the franchise and our close partner, Lionsgate, to share the ‘Uncle Drew’ movie with our audiences.”

- CNBC’s Lauren Hirsch contributed to this report

Pepsi CFO Hugh Johnston discusses earnings