U.S. District Judge John Bates said Michael Newdow had no legal basis to pursue his claim because he could not show he would suffer any injury from hearing the prayer.
Bates also ruled that Newdow's claim should be denied because he already had filed and lost a similar lawsuit at a federal appeals court in California last year.
Newdow argued that saying a Christian prayer at the Jan. 20 ceremony would violate the Constitution by forcing him to accept unwanted religious beliefs.
Attorneys representing Bush and his inaugural committee argued that prayers have been widely accepted at inaugurals for more than 200 years and that Bush's decision to have a minister recite the invocation was a personal choice the court had no power to prevent.
During arguments in federal district court Thursday, attorneys representing Mr. Bush and his inaugural committee said Newdow's case should be dismissed because he already litigated and lost a similar lawsuit at a federal appeals court in California last year.
The judge questioned both sides vigorously at a two-hour hearing but said he doubted a court could order the president not to include a prayer when he takes the oath of office.
"Is it really in the public interest for the federal courts to step in and enjoin prayer at the president's inauguration?" Bates asked.
Bates also questioned whether the lawsuit should be thrown out because the San Francisco-based 9th U.S. Circuit Court of Appeals ruled last year that Newdow did not suffer "a sufficiently concrete and specific injury" when he opposed prayers from being recited at Mr. Bush's first inauguration.
Newdow said his case is different this time because he actually has a ticket to attend the inauguration. He said being there live is different than four years ago, when he planned to watch the ceremony on television.
Justice Department lawyer Edward White scoffed at that claim, saying the issues in the two cases are the same and that Newdow still has not shown how he would be injured by hearing the prayer.
White said prayers have been recited at inaugurals for more than 200 years. He said Bush's decision to have a minister recite the invocation is a personal choice the court has no power to prevent.
Newdow won widespread publicity two years ago after winning his pledge case before the 9th Circuit, which ruled that public school's violated the separation of church and state by having students pledge to God.
The Supreme Court later threw out the ruling, saying Newdow could not lawfully sue because he did not have custody of his elementary school-age daughter, on whose behalf he sued.
Newdow refiled the pledge suit in Sacramento federal court this month, naming eight other plaintiffs who are custodial parents or the children themselves.