Desperate to raise money in the weeks before his first run for Congress, Michael Grimm e-mailed an ally in a bold bid to score large, and likely illegal, donations.

He asked for $10,000 donations from six people, when the legal limit for individual contributions is $2,400.

“We have very little time, as I need to start collecting checks as soon as today or tomorrow,” Grimm wrote in the Oct. 18, 2010, missive to Rabbi Yoshiyahu Yosef Pinto’s organization. “I think that if the Rabbi calls the six people and asks them to each write one check for the $10,000, then we can finish this in the next few days.”

Grimm went on to say he needed $190,000 to buy two weeks of television commercials and direct-mail solicitations.

“I can raise $120-$130 [thousand], but I must have the other $60,000 as soon as possible. Please e-mail me back, as I am very nervous and concerned about the final amounts of money,” he wrote in the e-mail, which was seen by The Post.

Grimm’s prayers were answered and the money was given, according to a source familiar with an ongoing federal probe of the congressman. A review of Grimm’s campaign filings for the time period showed none of the alleged $10,000 contributions.

Diana Durand, a former girlfriend of Grimm’s, pleaded guilty this year to recruiting straw donors to give money to Grimm’s 2010 campaign and that of another congressman. Grimm was not charged in the Durand case.

“A candidate who tries to get others to solicit contributions far in excess of the legal limit raises big red flags,” said Ken Boehm, a former prosecutor and chairman of the National Legal and Policy Center, a Virginia watchdog. Not reporting donations, or funneling them through straw donors, is illegal.

Grimm, a Brooklyn/Staten Island Republican who went on to defeat incumbent Michael McMahon in the race, has long been dogged by allegations he violated campaign-finance rules in 2010, including accepting too-large donations. He has denied wrongdoing. When contacted by The Post last week, he would not address the issues in his e-mail to the rabbi’s group.

“The incredulous source of these baseless accusations has proven over four years to be nothing more than part of a smear campaign that does not warrant a response,” a spokesman told The Post.

Grimm was indicted earlier this year on charges of tax fraud, perjury and obstruction related to a Manhattan restaurant he owned. His trial is scheduled to begin in February.

The former FBI agent is running for a third term next month against Brooklyn Democrat Domenic Recchia.

Pinto, an Orthodox mystic who lives in Manhattan and Israel, prompted the federal investigation against Grimm. The rabbi reported to federal authorities in 2010 that he was the victim of an alleged extortion scheme by two members of his inner circle, Israeli businessman Ofer Biton and p.r. executive Ronn Torossian.

Grimm, at the time, had become a follower of the rabbi, even though he is not Jewish and speaks no Hebrew. Pinto does not speak English.

Pinto, through a spokesman, would not comment.