* Rebels prepare offensive near Tunisian border
* Britain recognises Libyan rebels, frees assets
By Michael Georgy
NALUT, Libya July 28 (Reuters) - Rebels fighting in Libya's western mountains prepared on Thursday for a new offensive against Muammar Gaddafi's troops, raising pressure on the Libyan leader a day after Britain granted diplomatic recognition to the opposition.
With hopes fading of a negotiated settlement, both sides appear prepared for the five-month-old war to grind on into the Muslim holy month of Ramadan in August.
The rebels said they were planning to attack the town of Ghezaia near the Tunisian border in the next 48 hours, and a Reuters correspondent saw dozens of heavily armed pickup trucks heading for the nearby rebel-held town of Nalut.
"We are reinforcing the position around Nalut and we will attack Ghezaia tomorrow or the next day for sure. We plan to take it," Omar Fakkan, a rebel commander, told Reuters.
He said that forces from a number of rebel-held towns in the Nafusa Mountains were gathering in Nalut, ready for the attack.
Rebel fighters have taken large swathes of Libya since the start of an uprising to end Gaddafi's 41-year rule, and now control much of the Nafusa mountain range, the northeast of Libya and the western city of Misrata.
Yet they remain poorly armed and are often disorganised. Despite four months of NATO strikes, they have failed to reach the capital Tripoli and appear unlikely to make a breakthrough soon.
Gaddafi has scoffed at the efforts to end his rule and has weathered the now-stalled rebel advance and the NATO air raids on his forces and military infrastructure.
A recent flurry of diplomatic activity has yielded little, with the rebels insisting Gaddafi step down as a first step and his government saying his role is non-negotiable.
United Nations envoy Abdel Elah al-Khatib visited both sides this week with plans for a ceasefire and a power-sharing government that excludes Gaddafi, but to no avail.
Asked about Khatib's proposal, rebel leader Mustafa Abdel Jalil said: "We were surprised the day before yesterday that we are taking 10 steps back... and he says to share power with Muammar Gaddafi's regime. This is laughable."
Gaddafi also appeared defiant on Wednesday, urging rebels to lay down their arms or suffer an ugly death.
"We all lead this battle, until victory, until martyrdom," he said in an audio message aired at a pro-Gaddafi rally in Zaltan, 140 km (90 miles) west of his stronghold Tripoli.
RECOGNISING THE REBELS
Ramping up pressure on Gaddafi, Britain expelled his diplomats from London on Wednesday and invited the rebel National Transitional Council to replace them.
Foreign Secretary William Hague announced that Britain now recognised the rebels as Libya's legitimate government and unblocked 91 million pounds ($148.7 million) in frozen assets.
The United States and about 30 other nations have also recognised the opposition, potentially freeing up billions of dollars in frozen funds.
"This decision reflects the National Transitional Council's increasing legitimacy, competence and success in reaching out to Libyans across the country," Hague said in London.
Gaddafi's government said the British move was "illegal and irresponsible" and a "stain on the forehead of Britain".
"We will go to the International Court of Justice and the national courts in Britain, and we will use their justice," said Libya's deputy foreign minister, Khaled Kaim.
However, the British move won praise from rebels fighting in the western mountains.
"We are encouraged by what Britain has done and there is no way Gaddafi can stay in Libya," said Fakkan.
"The fighting will get much worse now because he will have to fight to survive and the Libyans do not want him." (Additional reporting by Joseph Nasr in Berlin, Rania El Gamal in Benghazi, Hamid Oul Ahmed in Algiers, Missy Ryan and Lutfi Abu Aun in Tripoli, Mussab Al Khairallah in Misrata; Writing by Lin Noueihed; Editing by Mark Trevelyan) ($1 = 0.612 British Pounds)