Investing

Investors see tech stocks as defensive now, immune to Trump tweets and other big market risks

Key Points
  • Tech shares have outperformed other sectors by a large margin, helping boost an otherwise flat market.
  • Investors put $4.7 billion into ETFs that track technology in May alone, part of a $10.2 billion influx for the year.
  • In addition to expanding margins and potential for growth, the sector has withstood geopolitical risks and some of the market-rocking comments from President Donald Trump.
Tech drives stock market rally
VIDEO3:5503:55
Tech drives stock market rally

Amid the incessant geopolitical tumult coming out of Washington and elsewhere, tech stocks have served as an island to which investors have been able to retreat and earn outsized returns.

In fact, there's an argument to be made that the sector actually has benefited from some of the more prominent headline risks. Tech stands to gain perhaps more than any other sector if President Donald Trump's saber-rattling trade strategy works out, and the administration-backed tax cuts have put more money in shareholders' pockets through a history-making jump in share buybacks that have been skewed toward the sector.

All in all, tech has served a multitude of purposes, from a cyclical play amid economic growth and rising interest rates, and as pure quality amid fears that corporate profits are peaking.

"They're really not driven by a lot of these headline macro variables. They've also stayed out of the Washington limelight in terms of being part of a tweetstorm or what have you," said Matthew Bartolini, head of SPDR Americas Research at State Street Global Advisors. "They're going to be more heavily driven by fundamentals, which continue to be supportive."

Investors have liked the results so far.

Tech shares are up 14 percent year to date on the , the best of the index's 11 sectors. The Nasdaq, weighted about two-thirds toward technology, has gained nearly 11 percent, easily outperforming other major indexes and reaching a 52-week high during Wednesday's rally. The S&P has risen about 3 percent for the year while the Dow industrials are up just over 1 percent.

In fact, the ProShares S&P 500 Ex-Technology exchange-traded fund, which tracks the index's performance minus the tech sector, is off 0.5 percent for the year.

Earnings rose 26.8 percent in the first quarter, fourth-best of all sectors, and are projected to grow 23.1 percent in the second quarter, third-best, according to FactSet. Technology companies, with a collective market cap of $6.2 trillion, now compose 26.4 percent of the S&P 500, by far the biggest share of the cap-weighted index, according to S&P Capital IQ.

More importantly, the sector has been immune to threats of a trade war and the market's continuing worry that inflation is brewing.

That's in good part because one of the main objectives in Trump's tariff threats has been to get China to stop pilfering intellectual property from American companies. Aside from the occasional Twitter fights the president has picked with Amazon CEO Jeff Bezos, Trump has been a friend to tech companies.

Jeff Bezos
Peter Foley | Bloomberg | Getty Images

As for inflation, technology is a sector that traditionally benefits from rising interest rates, making it an ideal play as the Fed continues to tighten monetary policy and as price pressure builds in various industries.

"You look at a sector where 90 percent of companies are increasing their margins — that's attractive for longer-term profitability and future growth," Bartolini said. "That points to some of these stocks being painted as quality."

As a result, investors are flocking to technology.

Investors put $4.7 billion into ETFs that track technology in May alone, by far the most for any sector, part of a $10.2 billion influx for the year, also the most of any category, according to SSGA.

Tech has led a surge into cyclical stocks that benefit from a stronger economy.

"Technology is one of the best sectors against rising yields, not just recently but historically," said Jim Paulsen, chief investment strategist at the Leuthold Group. "People have latched onto it. Tech's become the answer for everything. It's the play for growth ideas, it's the play for a solid fundamental growth story, and the play for rising interest rates."

Should Trump "step in it," Paulsen said, the tech sector is helping to provide some safety against the volatile spells the market has endured through the year.

Paulsen does worry about a "dotcom deja vu" playing out, a reference to the bubble that popped at the turn of the century when valuations skyrocketed for companies with little revenue stream as investors sought to get ahead of the internet business boom.

However, companies like the FAANGs — Facebook, Apple, Amazon, Netflix and Google parent Alphabet — all have strong earning capacity, though they are seeing seemingly stretched valuations. Netflix, for instance, trades at 100 times forward earnings and has a price-to-book ratio of 39.5, more than triple its peers, according to FactSet.

"A lot of companies back then had no earnings at all, and we don't have that now. But certainly we have a number of names that are at pretty extreme valuations," Paulsen said. "The bull is tech, the bear is getting lost. That might be correct, but it also smells like dotcom."

WATCH: Can tech keep the rally going?

Still a lot of upside for tech sector, says strategist
VIDEO3:4403:44
Still a lot of upside for tech sector, says strategist