Software stocks just posted their best month in 25 years — but the rally is sorting winners from losers based on one question: does AI consume your product or replace it?
Software stocks just posted their best month in 25 years — but the rally is sorting winners from losers based on one question: does AI consume your product or replace it?

The iShares Expanded Tech-Software Sector ETF climbed roughly 21 percent in May, its largest monthly gain since October 2001, as a wave of earnings and AI-driven deal-making reversed a selloff that had erased $285 billion from software valuations in a single February week. The rally was powered by Snowflake's $6 billion infrastructure commitment with Amazon Web Services and a 30 percent surge in Okta after earnings, but the headline masks a deeper repricing: the market is now sorting software companies by whether their revenue scales with agent activity or shrinks as AI replaces human seats.
"The world is no longer limited by the number of people, so agents are going to use more tools than ever," Nvidia Chief Executive Officer Jensen Huang said during his Computex keynote on June 1, directly addressing the "SaaSpocalypse" narrative that had gripped the sector. "This is actually an incredible time to be a software company."
Snowflake provided the quarter's defining catalyst. The data-cloud company reported fiscal first-quarter revenue of $1.39 billion, up 34 percent year over year, and raised its full-year product revenue guidance to $5.84 billion from a prior $5.66 billion. It also announced a five-year, $6 billion commitment with AWS for Graviton compute and AI infrastructure, and acquired Natoma, a startup building enterprise governance for the Model Context Protocol — the emerging standard for how AI agents access enterprise tools. Shares surged 87 percent for the month, closing at $255.55 on May 29, though the stock remains roughly 40 percent below its late-2021 peak above $400.
Okta delivered the second major catalyst. The identity-security company reported first-quarter revenue of $765 million, beating the $752 million consensus by $13 million, with non-GAAP earnings per share of $0.91 versus $0.85 expected. Management raised full-year revenue guidance to $3.185 billion to $3.205 billion and projected free cash flow margins of 27 percent to 28 percent. Shares jumped 30 percent on May 29 to a new 52-week high of $124.79, lifting its market cap to $20.7 billion.
The AI agent question splits the sector in two
Bank of America analyst Tal Liani drew the clearest line between winners and losers on May 18, reinstating ServiceNow at Buy with a $130 price target and Salesforce at Underperform with a $160 target on the same day. The logic: ServiceNow sits inside the approval, routing, and compliance infrastructure of large enterprises — the more autonomous agents proliferate, the more an organization needs a system of record for permissions and auditability. ServiceNow's first-quarter revenue of $3.77 billion, up 22 percent year over year, and 630 customers above $5 million in annual contract value supported that thesis. The stock recovered roughly 33 percent from its 2026 lows by the end of May.
Salesforce faces the inverse dynamic. Its core revenue is denominated in CRM seats — dollars per salesperson per month. When an agent handles part of a sales representative's job, the natural buyer reflex is to reduce a human seat rather than add an agent one. Salesforce's first-quarter results complicated the bear case: revenue of $11.1 billion beat the $11.05 billion consensus, and Agentforce annual recurring revenue reached $1.2 billion, up 205 percent year over year. But full-year revenue guidance of $45.9 billion to $46.2 billion slightly undershot Wall Street expectations, and the stock remains down roughly 30 percent for 2026 despite a 10 percent single-day surge on June 1.
What the rebound means for investors
The software basket has recovered its February losses at the index level, but the dispersion beneath the surface is extreme. Snowflake is up roughly 50 percent in the week after earnings; HubSpot gained 10 percent in a single session but remains down nearly 46 percent on the year; the median software company is still climbing out of a deep hole. Gartner has projected that 35 percent of point-product SaaS tools will be replaced by AI agents by 2030, while seat-based pricing adoption has dropped from 21 percent of vendors to 15 percent in roughly 12 months, according to industry data.
The market is rewarding companies whose consumption- or workflow-anchored pricing scales with agent volume — data platforms like Snowflake, identity and workflow platforms like ServiceNow and Okta, and observability players like Datadog. It is applying more skepticism to seat-denominated systems where AI can reduce human-user counts, including Salesforce's most exposed surfaces, Workday, and parts of the collaboration stack. The IGV ETF traded 37.7 million shares on May 29 alone, more than double its recent daily average, signaling heavy institutional flows into a sector that had been deeply underweight.
The risk for bulls is that the infrastructure thesis is already priced into names like Snowflake at 15x forward revenue. The risk for bears is that the picks-and-shovels analogy fits a few companies genuinely positioned on the path agents must travel. June brings another wave of enterprise software earnings that will test whether the May rally was a sentiment-driven snapback or the start of a durable re-rating.
This article is for informational purposes only and does not constitute investment advice.