Apple (AAPL -1.26%) has been on fire in 2023, driven higher by the remarkable resilience of the iPhone and a recovery by a broad cross section of technology stocks. Shares of the iPhone maker are up 32% so far this year, more than four times the 7% gains of the S&P 500. This marks a reversal of fortune for Apple, as its stock lost roughly 27% last year. 

The biggest contributor to its gains so far this year was Apple's better-than-expected financial results. Investors were surprised by just how well sales of the iPhone held up, which suggests that the struggling economy -- which has weighed on the stock -- could soon rebound.

What does this mean for those who missed out on Apple's current rally? Is now the time to buy in expectation of additional gains or avoid the stock due to its valuation and the economic volatility that remains? Let's take a look.

iPhone 14 Pro and iPhone 14 Pro Max stacked to show size difference.

Image source: Apple.

What's been weighing on Apple stock?

It's no secret that the principal driver of stocks and the broader market indexes during the past year or so has been the current economic conditions. The bear market was fueled by 40-year-high inflation and the resulting interest rate hikes designed to keep higher prices at bay. The economic uncertainty caused a pullback in consumer spending, which has resulted in slowing sales of the iPhone -- Apple's biggest seller.

This was clear in Apple's performance in fiscal 2022 (ended Sept. 24, 2022). Full-year revenue grew just 8%. While still respectable, it was a far cry from the 33% gains the company generated in 2021. As alarming as this might be for some investors, it's important to note that this is typical of a downturn. History is clear that when the economy begins to recover -- as it no doubt will -- consumers will return to normal spending habits, which will most likely include upgrading to the latest Apple device.

This suggests that pent-up demand could drive Apple stock higher once consumer discretionary spending returns to normal.

What (else) could drive Apple stock higher?

In addition to a recovery in consumer spending, there are other catalysts that could fuel Apple's stock rally.

The tech giant has a large and growing cadre of active devices -- and that number continues to grow. Earlier this year, CEO Tim Cook revealed that Apple had amassed an installed base of 2 billion active devices while also hitting new all-time highs in each of its major product categories. 

This translates to more revenue for the company, the result of its growing ecosystem. For example, iPhone users tend to visit the App Store, spending money on apps. They also avail themselves of other services, like paying using Apple Pay, streaming Apple TV+, or subscribing to Apple Music. Each of these apps makes Apple's ecosystem stickier, increasing the likelihood that not only will users stay around, they will also choose from the company's growing list of services -- thereby boosting revenue.

Another potential opportunity is Apple's long-rumored mixed-reality headset, which is expected to combine elements of virtual reality with augmented reality. While the company has yet to confirm the existence of this as-yet-to-be-released product, several major news outlets have suggested the device will be introduced during Apple's developer conference on June 5. Estimates vary widely regarding the expected price for the device, but most reports suggest a cost of about $3,000, with sales of about 1 million during the first year of release.

The jury is still out regarding the potential demand for such a product, but Apple has a strong track record of creating demand for products that many believed would be flops -- including the iPad and Apple Watch.

Apple is also expanding its presence in a number of emerging markets. The company just launched its online store in Vietnam and recently opened its first retail store in India, the world's second-largest smartphone market. These moves will help Apple tap into new and lucrative opportunities.

How to approach Apple stock now

Apple is currently selling for roughly 22 times trailing earnings, a lower valuation than the price-to-earnings (P/E) ratio of 24 sported by the S&P 500. That's a pretty reasonable price to pay for a company with a strong history of growth.

As I illustrated above, Apple has a number of growth drivers that could spark a continuing stock rally over the longer term. Experienced investors with the discipline to withstand a little volatility should consider buying Apple now or adding to a position, particularly given the company's track record and the long runway ahead.