U.S. stocks closed at session highs Wednesday as Wall Street weighed a surprising victory by Republican Donald Trump in the presidential election after futures and overseas markets plunged last night.

The S&P 500 rose 1.1%, the Dow Jones Industrial Average gained 1.4%, rising by 256 points, and the Nasdaq rose 1.1%.

European stocks traded higher following losses earlier in the trading session.

"What we saw last night in terms of the futures and the currency movements was a sense of panic, in a certain way," Gregory Daco, head of U.S. macroeconomics at Oxford Economics, said. "But now, what we're seeing is this sense of uncertainty with rebounding stock prices, with currencies falling back in line to where they were, with the exception, perhaps, of the peso, which is notable."

Trump, who will serve as the 45th president of the United States, surprisingly won New Hampshire, North Carolina, Florida, and Wisconsin, key battleground states both candidates needed to secure to win the election.

Prior to the election, markets were factoring in a win by Democratic nominee Hillary Clinton, who said in her concession speech Wednesday that "we must accept this result and then look to the future. Donald Trump is going to be our president. We owe him an open mind and the chance to lead." President Obama spoke today, saying he and his team will work with Trump on a smooth transition of power.

The election saw Senate and House Republicans maintain their majorities in Congress.

"We think the stock market selloff will be short lived," Deutsche Bank analysts wrote in a note prior to the markets opening on Wednesday. "This apparent Republican sweep is positive for the broad market and especially health care stocks. The only sector that might suffer from this election outcome is energy, as we think a greater U.S. oil supply outlook weighs on the oil price recovery."

If you liked this article you might like

Charts Signal Buying Opportunity for NVIDIA: Cramer's 'Off the Charts'

Dow, S&P 500 Set New Records as Fed Moves to Unwind Balance Sheet

Stocks In Negative Territory as Chances for December Hike Surge

Energy Stocks Lead a Neutral Market Even After Oil Inventories Spike

Here's Where Wall Street Stands