Artificial intelligence's (AI) advent into the mainstream delivered a boost to tech stocks in 2023 as the sector has enjoyed about a 40% gain in the market this year. AI captured headlines thanks to abilities such as generating art and delivering human-like responses in chat messages, as demonstrated by ChatGPT.

AI is a massive opportunity for tech companies. The global AI industry is forecasted to become a $1.8 trillion market by 2030, up from $142.3 billion last year.

The sector's long-term growth prospects make companies at the heart of AI-powered solutions a compelling investment, especially for an individual retirement account (IRA), as AI technology evolves over time.

But in an IRA, you also want stocks that will be there over the long haul. That's why these three AI stocks make good choices for a retirement account: Alphabet (GOOG 9.96%) (GOOGL 10.22%), IBM (IBM -1.05%), and Palantir Technologies (PLTR 3.73%).

AI stock No. 1: Alphabet

Alphabet makes an attractive investment simply on the strength of its leading market share in digital advertising. Add to that the company's capabilities in artificial intelligence, and it's a great stock for your IRA.

The company infused AI into a wide swath of its products, including Google, where AI helps the search engine better understand the intent of both verbal and typed search queries. As CEO Sundar Pichai stated, "Our new generative AI offerings are expanding our total addressable market and winning new customers."

For example, Instacart is improving its customer service workflows using Alphabet's AI technology. Alphabet itself relies on AI to manage YouTube's vast content, where more than 500 hours of videos are uploaded every minute.

AI is also a key component of the company's rapidly growing cloud computing business, Google Cloud. The number of customers adopting Google Cloud's AI solutions grew by over 15 times in the second quarter.

Alphabet's financials are excellent, since it makes massive sales from its existing lines of business. The company generated $74.6 billion in second-quarter revenue, along with an impressive $21.8 billion in free cash flow (FCF), giving Alphabet plenty of cash to invest in its AI capabilities.

AI stock No. 2: IBM

IBM possesses decades of AI experience, making history in 1997 when its AI technology beat the reigning world chess champion in a classic battle of man-versus-machine. In July, Big Blue debuted its latest AI solution, watsonx.

Over 150 businesses have already adopted the platform, including NASA, and at Wimbledon, watsonx was used to generate tennis commentary.

IBM is also developing quantum computers, which are more powerful than today's supercomputers since they employ quantum physics to process tremendous amounts of complex data. Quantum computers are a key step in AI's evolution, and IBM is viewed as the leader in the space.

Another factor making IBM a great AI investment, particularly for an IRA, is its dividend, currently yielding over 4%. A dividend delivers passive income to your IRA, and Big Blue's ability to fund it is solid. The company's FCF is expected to reach $10.5 billion this year, an increase of over $1 billion from last year. IBM has also paid quarterly dividends since 1916, illustrating its dependability.

AI stock No. 3: Palantir

Data analytics firm Palantir introduced its new Artificial Intelligence Platform (AIP) in April, and although the platform is new, the company is in a unique position to capitalize on the AI market.

That's because Palantir's systems were built to handle classified government data as its software helped the U.S. intelligence community fight terrorism. Today, Palantir's AI software continues to be used in high-stakes situations, such as assisting Ukraine in the war against Russia.

In the months since AIP's debut, CEO Alexander Karp stated, "the demand for AIP is unlike anything we have seen in the past twenty years." This customer demand helped Palantir capture contracts with the U.S. military's Special Operations Command and the Air and Space Forces.

Thanks to the success of its products, Palantir is experiencing strong financials. Its Q2 sales of $533 million represented 13% year-over-year revenue growth. Q2 also marked Palantir's third consecutive profitable quarter. It had net income of $27.8 million, an amazing turnaround from the prior year's net loss of $179.3 million. Profitability is an important attribute for any company you hold in your IRA, as it provides greater security that the company can last over time.

Further indication of Palantir's financial health is its Q2 adjusted FCF of $96 million, up from $60.9 million the year prior. Palantir also held over $3 billion in cash, cash equivalents, and marketable securities at the end of Q2. The firm is using some of its cash hoard to execute stock buybacks.

Combine Palantir with Alphabet and IBM in your IRA, and you'll have a nice mix of growth and income tech stocks with solid financials and demonstrated success in the burgeoning field of AI.