Japan's ruling Democratic Party made minor changes to a plan to raise the sales tax to win over dissenters, but opposition remains strong, setting the stage for a showdown that has the potential to split the party and deepen policy paralysis.

The agreement, which came after a meeting that dragged into the early hours of Wednesday, marked the third time in less than a year that Democratic lawmakers clashed as they struggle to reach consensus on Prime Minister Yoshihiko Noda's plan to double the sales tax to 10 percent to fund rising welfare costs.

The compromise will allow the cabinet to approve the plan when it meets on March 30 and submit it to parliament. But Noda has yet to find a way to win backing from the opposition, which controls the upper house and threatens to block the bill to force an early election.

Members of the ruling party could also revolt and vote against the bill.

If the Democrats are still split between pro- and anti-tax hike factions by the time they vote on the bill, this could lead to a deeper rift, said Seiji Adachi, senior economist at Deutsche Securities.

If ratings agencies downgrade Japan due to confusion surrounding its politics and yields rose sharply, this could lead to market turmoil and a decline in equities.

The ruling party inserted a clause in the plan that urges the government to meet targets set in its growth strategy agreed previously, but stopped short of some lawmakers' demands that failure to do so should be grounds to halt tax hikes.

The Democrats also agreed to omit mention that the government would prepare to raise taxes even further amid protests that this could damage the economy.

With public debt about twice the size of its $5 trillion economy, Japan has the worst debt burden among major economies and welfare costs steadily rise due to its ageing population.

Tax hikes are an important first step in rebuilding public finances, but the lack of support for the plan casts doubt on future efforts to tighten fiscal policy.

In a sign of the precarious state of Japan's public finances, new borrowing in the fiscal year starting in April is expected to exceed tax revenue for the fourth year in a row.

The government, led by Noda's predecessor Naoto Kan, agreed in June last year to double the 5 percent sales tax, but many politicians have tried to distance themselves from the plan as it fell out of favour with voters, leading some lawmakers to defect from the party.

Even though Noda's cabinet reaffirmed its commitment and agreed the basic outline of the plan last year, it has tried to build more consensus to prevent a split in the party.

The schedule is to raise the sales tax to 8 percent in April 2014 and then to 10 percent in October 2015, but the threat of mass defections before then could cause a larger political shake up.

Japan's sales tax is among the lowest in developed countries but many politicians consider tax increases to be politically taboo, given the drubbings ruling parties have got in past elections when even just the possibility of raising taxes was mentioned.

Even if the sales tax rises to 10 percent, this would only be a first step in reining in the nation's snowballing debt.

Japan, the world's most rapidly ageing society, expects two out of every five of its population will be 65 or older by 2060, reflecting low birth-rates and long life expectancy.

This demographic trend pushes up welfare costs, making it difficult to curb fiscal spending.

(Writing by Stanley White; Editing by Tomasz Janowski)