A rally in mining shares on the back of stronger metals prices also lent some support to the broader stock market.

The blue-chip FTSE 100 index <.FTSE> closed 0.5 percent higher after setting its highest level since mid-January.

Both the mid-cap <.FTMC> and small-cap <.FTSC> indexes hit all-time highs, maintaining momentum from Tuesday's session. Acacia Mining (>> Acacia Mining PLC) was among top mid-cap gainers, up 3.5 percent, after Credit Suisse raised its rating on the stock to "outperform".

The UK banking index <.FTNMX8350> rose 1.5 percent to an 18-month high, helped by a 1.2 to 2.1 percent rise in RBS (>> Royal Bank of Scotland Group plc), Standard Chartered (>> Standard Chartered PLC), Barclays (>> Barclays PLC). HSBC (>> HSBC Holdings plc) and Lloyds (>> Lloyds Banking Group PLC) after Yellen said the Fed would likely need to raise rates at its next meeting.

Higher interest rates translate into higher margins for banks, which have been under pressure from a "lower for longer" interest-rate environment.

"Hints at higher interest rates, a positive for lending margins, propelled bank shares higher. Lenders with a US presence including Barclays and HSBC were top risers on the FTSE 100," said Jasper Lawler, analyst at London Capital Group.

The mining index <.FTNMX1770>, up 0.5 percent, was also among the top gainers. Shares in BHP Billiton (>> BHP Billiton plc), Rio Tinto (>> Rio Tinto plc) and Anglo American (>> Anglo American plc) advanced 0.3 to 2 percent.

Elsewhere, construction company Ashtead (>> Ashtead Group plc) was up 2.5 percent, while insurers Prudential (>> Prudential plc) and Legal & General (>> Legal & General Group Plc) increased more than 1 percent.

Tour operator TUI was the biggest loser on the index, down 7.2 percent on profit taking after its results led to a jump on Tuesday. The stock erased its gains of the previous session.

Gambling firms Ladbrokes (>> Ladbrokes PLC) and William Hill (>> William Hill plc) were under pressure, however, down 3.2 and 2.8 percent, after HSBC cut its ratings on both stocks to "reduce" from "hold".

"A consumer downturn isn’t certain, but we analyse the bear case given the risks and conclude that, while the online market could remain flat, retail revenues could decline ... and operators could face EBITDA downgrades,” HSBC analysts said.

NEX Group (>> NEX Group PLC), a brokerage which reported higher earnings on volatile markets after Donald Trump's election as U.S. president, was also down 4 percent.

(Additional reporting by Atul Prakash and Kit Rees; Editing by Janet Lawrence and Hugh Lawson)

By Helen Reid