Stocks closed little changed as investors wrapped up a quarter that featured strong gains.
For the quarter, the S&P 500 rose 7.2 percent, its best quarterly gain since the fourth quarter of 2013. The Nasdaq Composite also notched a 7.1 percent quarterly gain, its best since first quarter 2017. The Dow Jones Industrial Average outperformed in the third quarter, rising 9.3 percent.
Health care was the best-performing sector of the third quarter, surging 14.1 percent, its best quarterly gain since the first quarter of 2013. Industrials and tech, meanwhile, rose 9.7 percent and 8.5 percent.
Equities rose broadly as investors cheered stronger-than-expected quarterly results. Calendar second-quarter earnings for the S&P 500 rose 25 percent on a year-over-year basis, with 77.6 percent of companies topping analyst expectations, FactSet data show.
Heading into the fourth quarter, investors will face uncertainty amid a hotly anticipated mid-term election in November. Democrats are expected to gain a majority in the House as well as increase their seat count in the Senate. This could delay, or even thwart, the Trump administration's economic agenda.
Trade concerns, which capped gains on Friday, will also linger heading into year-end. The fell marginally Friday to 2,913.98 while the Nasdaq eked out a small gain to close at 8,046.35. The Dow, meanwhile, climbed 18.38 points to 26,458.31 as Intel and Boeing outperformed.
The U.S. and Canada have not yet come to an agreement on their trade relationship with a Sept. 30 deadline rapidly approaching.
The two countries are trying to come to terms so that Canada can join a trade deal struck between the U.S. and Mexico. The new deal would replace the current North American Free Trade Agreement (NAFTA), which has been heavily criticized by President Donald Trump.
U.S. Trade Representative Robert Lighthizer said Tuesday the U.S. was ready to move ahead on a new NAFTA deal without Canada.
Trump, meanwhile, said Wednesday he was "very unhappy" with Canada's negotiation tactics, noting: "We don't like their representative [Chrystia Freeland] very much."
Trade has been an overhang for U.S. stocks for most of 2018 as investors try to assess how protectionist policies would impact the global economy and corporate profits.
"Unless we see some resolution, trade talks are going to heat up," said JJ Kinahan, chief market strategist at TD Ameritrade. "But first, we have to go through the earnings season" and hear what CEOs have to say on the matter.
Stocks gains were also capped as European shares fell after the Italian government set a budget deficit target that is three times higher than the previous government had planned.
The Stoxx 600 index — which track a broad swath of European stocks — fell 0.8 percent while the Italian FTSE MIB index dropped nearly 3.7 percent. Germany's Dax also fell 1.5 percent and France's CAC 40 declined 0.9 percent.
"The deficit agreed upon … while not the worst-case scenario, is still somewhat worse than market expectations," said Larry McDonald, head of the U.S. macro strategies at ACG Analytics and editor of The Bear Traps Report. He noted the deficit target puts Italy "in breach of its obligations."
Consumer spending rose 0.3 percent in August while the personal consumption expenditures (PCE) price index minus food and energy was unchanged for the month of August. The so-called core PCE is the Fed's preferred measure of inflation.
"On a year-over-year basis, inflation has met the Fed's publicly stated target. The FOMC can therefore continue to trudge forward on its journey toward normalization," Jeremy Klein, chief market strategist at FBN Securities, said in a note. "Given the robust economy, the lack of any deleterious upward pressure on consumer prices bolsters the bulls' case."
Tesla shares plummeted nearly 14 percent after the Securities and Exchange Commission sued CEO Elon Musk for fraud, marking the company's worst day since 2013. While sources close to the company told CNBC that the firm was also expecting to be sued, Tesla wasn't named as a defendant.
Boeing rose more than 1 percent after winning a $9.2 billion Pentagon contract to build the next Air Force training aircraft.
Intel shares jumped to close 3.1 percent higher after interim CEO Bob Swan said the company would be able to meet its full-year revenue outlook. The gains also lifted the S&P 500 tech sector, which was up 0.8 percent for the week.