Don't put all your eggs in one basket.

Spotify Technology (SPOT - Get Report) on Tuesday began trading on the public market for the first time ever, to much fanfare. Many have hyped the company's New York Stock Exchange direct listing as this year's high-flying tech stock debut.

While Spotify has amassed 71 million premium subscribers and 159 million monthly active users since it launched in 2008, it might not be worth going all in on for the long-term. That means don't tuck Spotify away in your retirement portfolio thinking it's the next Apple. 

"A better investment would be paying off your debt," said Arielle O'Shea, investing and retirement specialist at NerdWallet. She explains that as long as you have something like credit card debt or aren't fully contributing to a 401(K), investing in a high-flying tech stock like Spotify isn't wise.

If you are meeting financial and savings goals and have the time to research stocks such as Spotify, then it's appropriate to consider allotting 5% to 10% of your investments to stocks. But O'Shea notes that index funds and ETFs should get the bulk of any investor's portfolio given their propensity for diversification.

"The risk is putting all of your portfolio in one thing," O'Shea said.

For Spotify shares in particular, it's hard to figure out where they might go long term. Will Spotify maintain and grow those 159 million monthly active users? Can it increase the share of those users paying for premium subscriptions? Will another competitor unseat it? Hard to tell.

The competitive threats must not be discounted.

Watch more on the Spotify IPO below. 

Spotify's growing competition in the music streaming world comes from Apple Inc. (AAPL - Get Report) with its Apple Music, YouTube from Alphabet Inc. (GOOGL - Get Report) and Amazon Music from Amazon.com Inc. (AMZN - Get Report) . Those are some big rivals to square up to, even if streaming is a small part of their overall business.

While something of an industry laggard, Pandora Media Inc. (P) is, like Spotify, a streaming-centered, publicly traded company. Its stock has fallen nearly 60% in the last year and nearly 76% from its 2011 IPO price. Even still, it's competing for Spotify's listeners. 

Meanwhile, Spotify has been losing money even as it adds listeners, suggesting the business model could be flawed. Revenue grew last year, but net losses continued to build. That doesn't bode well for the stock as Spotify begins to report its quarterly results. 

At least for now, it's somewhat unclear as to where Spotify's stock could trade. In 2017, privately exchanged shares traded hands for anywhere from $37.50 to $125, according to Spotify's S-1 registration with the Securities and Exchange Commission (SEC). And on Tuesday, Spotify's stock was all over the map after opening at $165.90.

Shares closed at $149.01.

If you're interested in gaining exposure to the tech sector, consider a stock with a higher dividend yield, better growth prospects or super-strong management. Or, all three. TheStreet's Jonas Elmerraji wrote in March that Apple, Intel Corp. (INTC - Get Report) and the SPDR Technology Select Sector exchange traded fund (XLK - Get Report) all make smart retirement portfolio picks.

Not all is bad for Spotify. According to Elliot Lutzker, chair of the corporate law practice group at Davidoff Hutcher & Citron LLP, "there's no reason not to invest in it." As a 10-year-old company with what Lutzker considers strong growth prospects, it could be a fine investment for anyone willing to take on a little uncertainty.

Retirement Is Coming. It's never too early -- or too late -- to plan, save and invest for the retirement you want and deserve. Let TheStreet's new premium subscription newsletter, Retirement Daily, give you the insider's edge on how to maximize and protect your most important investment, your retirement savings. Learn more about Retirement Daily and get a free trial subscription.

Apple, Alphabet and Amazon are holdings in Jim Cramer's Action Alerts PLUS Charitable Trust Portfolio . Want to be alerted before Cramer buys or sells the stocks? Learn more now.

Don't miss any of TheStreet's retirement tips from expert Robert Powell. Catch up here: