Scottish National party leader Nicola Sturgeon has offered to help make Ed Miliband the next prime minister even if Labour wins fewer seats than the Tories on 7 May. Her appeal comes as she angrily rejects claims that she thinks he is not up to the job.

Writing in the Observer – as a furious row erupted over disparaging private remarks she allegedly made about the Labour leader – Sturgeon challenges Miliband to lead Labour into an anti-austerity alliance with the SNP whichever party is the largest in the House of Commons on 8 May.

In terms that will enrage many MPs, Sturgeon throws down the gauntlet to the Labour leader, saying: “If together our parties have the parliamentary numbers required after 7 May, and regardless of which is the biggest party, will he and Labour join with us in locking David Cameron out of Downing Street?”

After a momentous week, in which she was widely hailed as the winner of a seven-way televised leaders’ debate on ITV, Sturgeon says the election is “one like no other in modern times, and the power of the Westminster establishment is being challenged as never before”.

The SNP leader uses her article to deny that she said in private discussions with the French ambassador that Miliband was “not prime minister material” and that she would prefer Cameron to stay on in No 10.

The Daily Telegraph said that her comments were recorded in a Foreign Office memo which described her conversation with the ambassador on 26 February this year.

Sturgeon, who has been feted in Scotland since Thursday’s debate, confronts that claim head on: “I’d like to address the matter of the leaked UK government memo about my meeting with the French ambassador. This story has already been shown to be 100% untrue – having been comprehensively rejected by both the French ambassador and consul general.”

With the general election race between Labour and the Tories too close to call, and a hung parliament looking highly likely, Sturgeon knows her party could hold Miliband’s fate in its hands on 8 May.

Labour has already ruled out any formal coalition with the SNP, which is set to gain a record number of Westminster seats. But it has stopped short of ruling out a more informal alliance, under which the SNP would support it on a vote-by-vote basis.

An Opinium poll for the Observer shows the two main parties in a dead heat with four-and-a-half weeks to go until polling day, underlining the likely necessity for dealmaking after the election. Both the Conservatives and Labour are on 33%. The Tories have dropped one percentage point since last weekend, while Labour is unchanged. Ukip is on 14%, up one point; while both the Greens, who are unchanged, and the Liberal Democrats, who have dropped one point, are on 7%.

The polling, carried out following Thursday’s leaders’ debate in which Sturgeon, putting forward a firm anti-austerity message, was judged by many to have been the most impressive, puts the SNP up one point, on 4%.

Miliband jumped into the controversy over the alleged Foreign Office memo as he tried to turn the row to his party’s advantage.

He said: “What it shows is that while in public the SNP are saying they don’t want to see a Conservative government, in private they are actually saying they do want a Conservative government. It shows that the answer at this general election is if you want the Conservatives out, the only answer is to vote Labour for a Labour government.”

Labour sources went even further accusing the Tories and SNP of being in an “unholy alliance” to boost the nationalists’ vote at the election. Scottish Labour leader Jim Murphy said it was a “devastating revelation that exposes the uncomfortable truth behind the SNP’s general election campaign”.

“For months Nicola Sturgeon has been telling Scots she wants rid of David Cameron yet behind closed doors with foreign governments she admits she wants a Tory government. If Scotland votes SNP in May then Nicola Sturgeon will get her wish – the Tories will be the largest party across the UK and David Cameron will return to Downing Street. Only a vote for Labour will deliver a Labour government.”

Sturgeon says in her article that her experience in politics north of the border has proved that governments can work successfully even when there is no party with a clear majority. “Scotland’s experience since 1999 has shown how both coalition and minority governments can work well. The SNP’s experience of the latter from 2007 to 2011 saw us pass legislation on a vote by vote basis, and was a stable administration.

“As deputy first minister in that government, I learned how to balance sticking to your principles with making the concessions needed to get the work of government done.

“And I learned how influential smaller parties can be when they have a good idea, when they work hard to keep you to your word and when they encourage you to be bolder.”