Alex Salmond's party will lodge court papers on Tuesday
The Scottish National Party says it has raised £50,000 to proceed with legal action over the prime ministerial debate on BBC One on Thursday.
The SNP will lodge the necessary papers instigating the action at Edinburgh's Court of Session on Tuesday.
The party said it was not trying to stop the broadcast but it wanted an SNP politician included "for balance".
Labour, the Conservatives and the Liberal Democrats said the SNP was more interested in grabbing headlines.
The SNP made its announcement after starting a "fighting fund" to raise the money over a 48-hour period.
The party said its proposed action would seek to ensure the debate was broadcast in Scotland "with the nation's political make-up fairly reflected".
This would involve either having SNP representation in Thursday's debate or through an agreement to have a further "fair leaders' debate" organised before polling day.
SNP deputy leader Nicola Sturgeon said: "The fact that we have been able to raise this money in a day and a half simply underlines the strength of feeling people across Scotland have on this issue and the BBC's refusal - despite its clear duties as a national broadcaster - to properly and fairly reflect the political make-up of this country.
"Donations have come in from ordinary Scots who simply share our anger at the way Scotland has been treated by the BBC.
"We will now take our case to the Court of Session where we will argue that basic fairness and democracy should prevail."
Labour said SNP leader Alex Salmond was "completely unable" to explain why he refused to take part in a BBC Scotland debate on Sunday night, or why he was boycotting the main BBC Scotland election debate this weekend.
The SNP's notice of legal action came after the BBC Trust did not uphold a complaint from the Nationalists and Plaid Cymru over their exclusion from the debate.
Plaid Cymru has said it supported the SNP's stance but would not take part in joint action, due to separate legal systems.
A Labour spokesman said of Mr Salmond: "He is more interested in trying to win newspaper headlines, because he knows he isn't winning the argument - he wants to stand at a podium, but isn't even standing in the election."
Conservative Scottish affairs spokesman David Mundell, added: "Alex Salmond's attempts to be part of the UK leaders' debates is nothing but posturing.
"He has been offered a space on four Scottish leaders' debates and refused three of them.
"Instead of making believable statements on how to bring down the debt, or sort out the economy, his one main fight of the campaign is to get himself on the TV."
Liberal Democrat leader Nick Clegg branded the proposed legal action as a "measure of desperation".
Mr Clegg, speaking on BBC Radio Scotland, said: "The broadcasters have made their decision, they've invited the leaders of the parties competing across the United Kingdom to be prime minister of this country.
"So, quite understandably, they haven't invited Alex Salmond."
Mr Clegg said the legal action could mean the televised debate would not be broadcast in Scotland.
He said: "I understand he's got a bone to pick with the broadcasters and he should pursue that, but he shouldn't penalise the Scottish people and prevent them from watching the debate."
The SNP said they hit their target through raising small contributions online from more than 1,600 donors.