Apple Inc. doesn’t make hot videogames such as “Fortnite,” or consoles such as the Xbox. But with little fanfare, Chief Executive Tim Cook has turned the maker of the iPhone into one of the world’s largest videogame companies.

The key is the App Store, its digital marketplace, where the company sells and distributes thousands of games by other companies and developers, from Epic Games Inc.’s “Fortnite” to Tencent Holdings Ltd.’s “Honor of Kings”—and takes a 30% cut of sales. That explains a lot about the tech giant’s current...

Apple Inc. doesn’t make hot videogames such as “Fortnite,” or consoles such as the Xbox. But with little fanfare, Chief Executive Tim Cook has turned the maker of the iPhone into one of the world’s largest videogame companies.

The key is the App Store, its digital marketplace, where the company sells and distributes thousands of games by other companies and developers, from Epic Games Inc.’s “Fortnite” to Tencent Holdings Ltd. ’s “Honor of Kings”—and takes a 30% cut of sales. That explains a lot about the tech giant’s current battles with rivals.

Apple raked in more profits from games than Xbox maker Microsoft Corp. , gaming giants Nintendo Co. and Activision Blizzard Inc. and PlayStation maker Sony Corp. —combined—in its fiscal year 2019, according to a Wall Street Journal analysis of figures released as part of the company’s recent antitrust trial.

Apple’s operating profits from games that year totaled $8.5 billion, according to the Journal analysis, exceeding the other four companies’ combined gaming operating incomes in the same period. The tech giant said operating margins discussed during the trial were flawed and as a result are too high.

Apple’s dominance, however, is under threat. Its position as the gatekeeper to the gaming economy places it at odds with Facebook Inc., Microsoft and “Fortnite” maker Epic Games Inc. as each company prepares for the next frontier in technology: virtual reality.

Many digital activities—from search to social to shopping to live events —could take place inside of games in the coming years. Industry global revenue from videogames is expected to almost double to $198 billion in 2024 compared with 2016, according to estimates by technology consulting firm Activate Inc. The biggest chunk of that growth is from mobile games, which Activate predicts will generate $103 billion in 2024.

Men play the game 'Honor of Kings' on their mobile phones in Beijing last August. It was the top grossing game last year in Apple’s App Store, according to Sensor Tower.

Photo: roman pilipey/Shutterstock

The risk for Apple is that its role as the gatekeeper between the gaming world and its more than 1 billion iPhone users as well as the fee it collects as the middleman could be disrupted—whether by legislation, court order or regulatory action. Epic sued the company in 2020, alleging that it stifled competition. Because of Epic’s lawsuit and increased scrutiny of Apple’s sway, lawmakers and regulators from Washington to Brussels are considering ways to potentially upend the company’s power, which some fear hurts rivals.

Another threat to Apple’s profit engine comes from China. New rules in that country aim to decrease the number of hours young people can play games. Three of the top five grossing mobile games in the App Store are from China, including the No. 1 title “Honor of Kings” from Tencent, which generated an estimated $2.5 billion last year from users, according to analytics firm Sensor Tower.

Globally, customers spent a total of $45 billion on mobile games through the App Store in fiscal 2020, according to Sensor Tower. Almost 31% of that money was spent in China while 26% was in the U.S.; Apple’s cut came out to an estimated $13.5 billion or about 5% of Apple’s overall sales that year of $275 billion. Fifty percent of Apple’s revenue came from hardware sales of iPhones.

Apple doesn’t break out revenue from the App Store; instead it includes the business as part of its services category, which it said generated $53.8 billion in sales last year. That category also includes music, iCloud, Apple TV, advertising and extended warranties. It doesn’t say how profitable each of its product categories is but disclosed an overall company operating profit of $66.29 billion during the period.

A new gold mine

That such a large part of Apple’s business comes from the gaming world is almost a fluke. After releasing the iPhone in 2007 and seeing developers hack their gadgets, it designed the App Store so users could download third-party software to their phones under Apple’s control. Apple’s late co-founder Steve Jobs and his team came to realize that the store could be a new gold mine.

In 2008, the year the App Store launched, it had 500 apps, many of them games. Apple’s profits from gaming got bigger as the app economy expanded. The shift became even more important under Mr. Cook as he looked to combat stagnating iPhone sales.

In a nod to how important hard-core gamers are to the company now, Apple introduced its new iPhone 13 Pro last month with upgrades to the screen aimed at giving a smoother video experience. The feature is particularly attractive to those who use it for gaming.

Bri Thomas, pictured here with her 3-year-old son, said she pays as much as $50 a month to Apple's App Store to access special perks in mobile games.

Photo: Matt Thomas

Apple is appealing to a rather small group. Just 6% of App Store game customers in 2017 accounted for 88% of all the store’s game billings for the year, according to court records. On average they spent more than $750 annually. The biggest spenders, who made up 1% of Apple gamers, generated 64% of billings and spent on average $2,694 annually.

Blockbusters include “Honor of Kings,” which allows users to battle as historical Chinese characters and was the top grossing game last year in the App Store, according to Sensor Tower. Other top money generators are “Pokémon Go,” an augmented reality game based on the popular Japanese anime, and “Candy Crush Saga,” a puzzle game where users match clusters of jelly beans and gumdrops.

Bri Thomas, a 38-year-old human resources professional from Dallas, likely fits into the medium-high category of spenders who accounted for 3% of gamers and generated 20% of billings in 2017. On average that group spent about $373 each year.

She said she typically spends as much as $50 each month. The convenience of having the iPhone in her pocket means it is easy to spend money to access special perks in mobiles games such as “Empires & Puzzles,” a puzzle game.

“It’s very convenient,” Ms. Thomas said. “You can get carried away really easily.”

Lifting the veil

By Mr. Cook’s own admission, he is not a gamer. He said so during an appearance before a judge in the antitrust case that consumed Apple’s attention for much of the past year.

In August 2020, “Fortnite” maker Epic filed a lawsuit against Apple claiming the company held an improper monopoly over distribution of software on its mobile devices and forced developers to use its in-app purchasing system. They went to trial in May.

Apple vehemently denied the claims, pointing to everything from Google devices to the XBox as alternative ways for users to play games and arguing that its fees were in line with the industry and fair. U.S. District Judge Yvonne Gonzalez Rogers mostly agreed with Apple in an early-September ruling.

That doesn’t mean Apple is out of danger. The judge ordered the tech giant to let developers inside their apps advertise alternative, cheaper payment methods that exist outside of Apple’s App Store. That raises the possibility that game developers could deny Apple money for those games.

CEO Tim Cook entering the U.S. District Court in Oakland, Calif. in May, for Apple’s courtroom battle with Epic Games Inc.

Photo: Philip Pacheco/Getty Images

The case lifted the veil on Apple’s gaming business. The company, which has long prized secrecy as it seeks to draw users to new products and services, keeps under wraps the extent to which gaming is at the center of its profits and business.

Apple said records introduced during the trial purportedly showing profitability of the digital store weren’t correct, and Mr. Cook testified in court that the company doesn’t do such analysis. But Judge Gonzalez Rogers, who reviewed Apple’s records under seal, contradicted this assessment.

She wrote that Epic’s claims that Apple generated operating margins of more than 75% from the App Store are, in fact, correct and characterized them as “extraordinarily high.”

App sales may be small in comparison with overall revenue but court documents suggest they are almost pure profit for Apple. As part of the legal battle, Apple handed over millions of internal documents to Epic. Using those materials, an expert witness for Epic named Ned Barnes, a forensic accountant, calculated that Apple’s App Store generated a 79.6% operating margin—a measure of profitability that subtracts costs from revenue—during both the 2018 and 2019 fiscal years.

The late discovery of an internal report sent to Mr. Cook supported that assessment. The report, according to court records, included the company’s own calculations for the store’s operating margin of 74.9% and 77.8% for fiscal 2018 and 2019, respectively.

“Mr. Barnes made appropriate adjustments based on sound economic principles to reach his conclusions,” the judge wrote. “Apple’s protestations to the contrary, notwithstanding the evidence, shows that Apple has calculated a fully burdened operating margin for the App Store as part of their normal business operations.”

Another view of how much Apple collects from its App Store—and gaming—comes from Sensor Tower, the analytics firm. It estimated that Apple received $15.9 billion in revenue from the App Store in fiscal 2019, with 69% of that amount coming from games. Using Apple’s operating margin calculation described in court records, the company’s App Store had an implied operating profit of $12.3 billion that year—or nearly one out of five dollars of the company’s overall operating profit.

Gaming alone would have earned $8.5 billion, according to a Journal analysis. That is $2 billion more than the operating profit generated in the sector during the equivalent 12-month period from gaming giants Sony, Activision, Nintendo and Microsoft, according to company filings from the first three and an analyst estimate for Microsoft.

Apple said Friday the disputed operating margins come from an analysis that doesn’t include many joint costs for the App Store and results in margins that it describes as being too high because it includes all revenue but only a fraction of the costs. During the trial, Apple vehemently denied the accuracy and during public court testimony Mr. Cook took issue with the margins as well.

Share Your Thoughts

How have your habits in playing videogames changed over the years? Join the conversation below.

Under questioning from Apple’s lawyer, he said the company had never tried to determine the specific profitability of the App Store as a stand-alone business and that he couldn’t put an exact figure on how profitable it might be. The practice of not tracking business-unit profitability, he said, dated back to a desire by Mr. Jobs to encourage cooperation across the company’s various units. The internal document that calculated operating margin, which wasn’t made public, was a “one-off presentation,” he said.

Nevertheless, Mr. Cook said he believed the App Store was profitable even without calculating it. “We haven’t done that, but, you know, I have a feel—if you will,” Mr. Cook said. While being questioned by the judge, Mr. Cook said a majority of App Store revenue came from games.

The judge ruled that Apple wasn’t a monopoly in part because the mobile gaming market is evolving so quickly, including the nascent streaming game services. Similar to how Netflix Inc. offers movies, Microsoft, chip maker Nvidia Corp. and others are pushing subscription game services that could be accessed on iPhones through websites. That allows them to bypass the App Store.

As for Apple’s gaming economy, it is unclear what happens next. Epic plans to appeal the judge’s ruling, and some legal observers said Apple will appeal the order to stop prohibiting developers from communicating cheaper alternatives to the App Store. The company said it is reviewing the matter.

Sarah E. Needleman contributed to this article.

Write to Tim Higgins at Tim.Higgins@WSJ.com and Sarah E. Needleman at sarah.needleman@wsj.com