Apple CEO Tim Cook greets customers as they prepare to purchase a new iPhone X at an Apple Store on November 3, 2017 in Palo Alto, California. Justin Sullivan | Getty Images

Apple was in a sour spot shortly after Tim Cook took over as Apple's CEO. After the death of Steve Jobs in 2011, critics began questioning if the company could continue to produce breakthrough products like iPod, iPhone and iPad. That pessimism continued into 2012 and 2013 as rivals like Samsung pushed forward with iPhone alternatives that had bigger screens and wild features. Apple was doomed, according to the naysayers. The company lost its spiritual leader, and an "operations" guy like Cook didn't have the instincts to create another disruptive product. The company continued to beat earnings expectations, but the longer term outlook didn't look great. The naysayers were wrong. Apple under Cook hasn't invented a new, game-changing product like the iPhone. Instead, he's leveraged the iPhone's success into new areas of growth. Under Cook, the iPhone has become the linchpin for the entire Apple ecosystem. Even though unit sales have fallen over the last couple years, the company has built a compelling system of accessories and services around it. Cook has convinced investors that its story reaches far beyond how many iPhones it can sell each quarter. Apple's stock is up about 480% since Cook took over in August 2011. It became the first publicly traded company to reach a $1 trillion market cap in 2018. And even after a rough start to 2019 when Apple shocked investors by revising its holiday quarter guidance down, the stock completely recovered by the end of the year, blowing past a $1 trillion market cap once again. It's up about 45% since the unveiling of the iPhone 11 last September, adding about $400 billion in market value. To put that in perspective, Apple added the value of more than four Teslas in just four months. (On the other hand, Apple's stock is historically expensive. It's price-to-earnings, or P/E, ratio climbed throughout 2019, ending the year at 24.7, the highest level since 2010, according to FactSet.)

So what attributed to Cook's amazing run? And what continues to drive the stock higher in the new year? Let's break it down:

Growing the iPhone

Early in Cook's tenure, Apple's main goal was expanding the iPhone's presence around the world. At the time, the iPhone was only available on Verizon and AT&T in the U.S., and it wasn't until 2013 that the last major carrier, T-Mobile, finally started selling it. From there, the iPhone expanded around the globe, eventually landing its biggest prize in 2014 with China Mobile, the largest carrier in China, which had about 760 million subscribers at the time. Later that year, Apple kicked off a major "super cycle" of iPhone sales by breaking with its tradition and releasing two iPhone 6 models with larger screens that matched its rivals. The company sold 74.5 million iPhones in the fourth quarter alone. But that was just about the peak of iPhone sales, and doubts began to swirl about its ability to grow at such a massive scale. That's where the next chapter in Cook's story began. The iPhone was a once-in-a-generation product, and it would've been technically impossible to recreate that magic. The writing was on the wall, and Cook formed a new path for growth outside the iPhone.

Services

Today, Apple talks about its growing suite of services more than anything else. The segment includes products like iCloud storage, App Store sales, Apple Card, Apple Music subscriptions and the billions Google pays to be the default search engine on Apple products. We'll get the final results for Apple's services performance for 2019 when the company reports earnings on January 28. Apple made an even bigger push into services last year with the launch of several new subscription products, like Apple News+, the Apple Arcade gaming service and the streaming TV service Apple TV+. It's still too early to judge the success of those subscription services, especially Apple TV+, since it comes free for one year with the purchase of a new Apple gadget. (Even Apple has said Apple TV+ won't be material to its financials.) But the foundation is in place for Apple to get more out of its subscription services in the coming years as it builds out its content offerings. Finally, Cook gave us a hint during Apple's last earnings call that the company is noodling around with the idea of an "Apple Prime" subscription bundle that would include everything from yearly iPhone upgrades to streaming services for one monthly fee.

Wearables

Apple may talk about services more than anything else, but the growth in its wearable accessories business has become a much more interesting story. Apple's wearables business includes devices like the AirPods, AirPods Pro, Apple Watch and Beats headphones. Last year, Apple upgraded the "regular" AirPods with improved battery life and an optional wireless case. In the fall, it launched the AirPods Pro, which sport a new design and high-end features like noise cancellation. And the Apple Watch's entry price dropped to $199, making it an attractive option as competitors like Fitbit faltered in the smartwatch space. Between AirPods and Apple Watch, Apple has the wearables market locked up. Wearables have turned into the sleeper hit for Apple, with Citi analysts estimating last month that the segment could show $10 billion in sales for the holiday quarter. That would make Apple's wearables business alone about seven times larger than all of Twitter. And again, it's all tied to the iPhone, giving Apple the leverage it needs to keep its customers locked in when they're ready to upgrade again.

5G optimism