The FTSE 100, which started the day in negative territory, reversed course to end 0.4% higher, although it lagged its European counterparts due to weakness in oil majors Shell and BP.
The domestically-focused midcap index rose 0.7%, helped by strength in the local currency, the pound, whose gains were prompted by the U.S. Federal Reserve opening the door to the possibility of a rate cut.
After a slew of back and forth trade threats between the U.S. and China, investors welcomed comments from China's commerce ministry urging dialogue and negotiation to solve the differences.
That supported shares in Asia-focused banks including Prudential and Standard Chartered, while miners also climbed higher.
"In the era of heightened trade tensions, any language that isn't hostile, and advocates further dialogue, is seen as a step forward. The situation is far from diffused, but the absence of aggression has promoted traders to snap up stocks," David Madden, CMC Markets analyst, said.
Oil heavyweights, however, weakened as crude prices fell to their lowest since January as Russia's top oil producer said it opposed extending joint cuts with OPEC until the end of the year.
Hargreaves Lansdown tumbled 4.6%, among top losers on the main index, after well-known money manager Neil Woodford suspended trading in one of his funds, which is included in six of Hargreaves Lansdown's Multi-Manager funds.
On the midcap index, shares in Woodford Patient Capital Trust, a listed fund run by Woodford, slumped to an all-time low as investors were spooked by the suspension. Stock ended down 7.2%.
"It's been a tough few years for Woodford and things look like they will get worse still," Markets.com analyst Neil Wilson said.
Another stark reminder of the toll the prolonged and delayed Brexit process is taking on consumers came from the British Retail Consortium, whose data showed shoppers cut back spending in May by the most in more than two decades.
Shares of retailers and consumer goods companies declined in response, with online grocer Ocado down 5% on the FTSE 100. Fashion retailer Ted Baker slid 2% on the mid-cap index.
a graphic on performance of UK fund managers over the last 2 years, click
(Reporting by Shashwat Awasthi and Muvija M in Bengaluru, editing by Ed Osmond)
By Muvija M and Shashwat Awasthi