The FTSE 100 has surged through the level it closed at last Thursday, recovering all of the ground it had lost in the wake of the Brexit vote.
The FTSE 100 share index closed up 3.6% at 6,360.1 after a flurry of last-minute trading.
At the close of trade on Thursday last week, before the referendum vote, the FTSE 100 ended the day at 6,338.10.
The pound also strengthened against the dollar and euro.
Analysts said the sharp recovery in the FTSE 100 was unexpected.
"It is safe to say that, of all the post Brexit outcomes discussed across the City over the past few months, 'buying frenzy' was not one that was viewed as very likely," said Chris Beauchamp, senior market analyst at spread betting firm IG.
"The plethora of bargains on offer, plus a welcome period of calm in the UK/EU relationship has provided the opportunity for markets to recover in impressive fashion," he added.
However Joe Rundle, head of trading at ETX Capital, warned reality was likely to bite soon.
"What we're seeing in the FTSE is hope in Britain being able to ride it out by remaining part of the single market. This looks like wishful thinking."
The FTSE 250 - which contains more UK-focused companies - closed 3.2% higher on Wednesday, but still remains more than 7% below its pre-Brexit level.
The pound rose 1.2% against the dollar to about $1.35, although it also remains well below levels reached before the referendum.
The pound had risen as high as $1.50 on Thursday as traders anticipated a 'Remain' vote, but by Monday it had plunged to a 31-year low against the dollar.
Sterling rose 0.8% against the euro on Wednesday to ââ¬1.2159. Before last week's referendum it had been trading around ââ¬1.30.
Shares in Asia also continued to rise on Wednesday, and stock markets across Europe followed suit. Germany's Dax index ended the day 1.8% higher while France's Cac 40 closed up 2.6%.
US markets joined in the global stock market rally, with the Dow Jones Industrial Average rising 1.3% and the wider S&P 500 index up 1.4%.
Michael Hewson, chief market analyst at CMC Markets, said investors had been reassured by hopes that Britain's EU exit wouldn't happen immediately, meaning the status quo was unlikely to change in the short term.
"Whilst that doesn't remove the uncertainty with respect to the eventual outcome, it also means that markets are going to have plenty of time to settle into their new-found reality and equilibrium," he said.
But Adam Jepsen, founder of Financial Spreads, urged caution: "Any investors who think the markets have calmed down should think again. It is far more likely that we are in the eye of the storm."
Shares in the financial sector - which had been particularly hard-hit in the wake of the referendum - continued to recover, with Prudential up 5.5% and Barclays 4.9% higher.
The increases came despite credit rating agency Moody's cutting its outlook on the UK banking sector to "negative" from "stable" late on Tuesday. Moody's also downgraded its outlook on the ratings of a number of UK banks and insurers.
Shares in housebuilders - another sector that suffered in the dramatic sell-off on Friday and Monday - were also higher. Persimmon and Barratt Developments were both closing over 7% higher.
After losing some ground on Tuesday, the price of gold rose 0.4% to $1,317.75 an ounce.
Gold is viewed as a safe asset in times of uncertainty and the price of the precious metal hit a two-year high on Friday in the wake of the referendum result.
Government bonds are also considered safer investments. Continuing high demand since the referendum meant the return on 10-year UK government bonds remained close to Monday's record low, when the yield dropped below 1% for the first time.
High demand tends to push up bond prices, and when the price of bonds rises their yield falls.
http://www.bbc.co.uk/news/business-36660133