The FTSE 100 index closed up 35.52 points at 6,175.49, helped by oil giants BP and Royal Dutch Shell.
However shares in soft-drinks makers fell after the announcement of a tax on sugary drinks in the Budget.
Shares in Britvic - maker of Robinsons squash - fell 9.5p to 700p while Vimto maker Nichols fell 7% to 1219p.
Shares in the London Stock Exchange Group fell 1.2% after the company agreed terms to merge with Germany's Deutsche Boerse.
On the currency markets, the pound fell 0.24% against the dollar to $1.4118 and little changed against the euro at â‚¬1.2733.
(Close): London's benchmark share index rose, helped by a strong performance from oil companies as the price of crude climbs.