Government meetings can include an opening prayer without running afoul of the Constitution, the Supreme Court said Monday.

The court ruled in favor of the town of Greece, N.Y., a Rochester suburb that has opened its monthly public meetings with a Christian prayer since 1999. Two residents, one Jewish and the other atheist, claimed that because the prayers were almost always Christian, the practice amounted to government endorsement of a single faith.

The Supreme Court last considered the issue of government prayer in 1983, ruling that the Nebraska legislature did not violate the Constitution by opening its sessions with a prayer from a Presbyterian minister.

But the challengers in the New York case argued that the meetings of the Greece town board were different, because members of the public who sought action from the board were legally required to attend and were not simply part of a passive audience — drawing attention to themselves if they declined to participate in a prayer that was contrary to their beliefs.

Justice Anthony Kennedy, writing for the majority, said the prayers are ceremonial and in keeping with the nation's traditions. "The inclusion of a brief, ceremonial prayer as part of a larger exercise in civic recognition suggests that its purpose and effect are to acknowledge religious leaders and the institutions they represent, rather than to exclude or coerce nonbelievers," Kennedy said.

Justice Elena Kagan, in a dissent for the court's four liberal justices, said the case differs significantly from the 1983 decision because "Greece's town meetings involve participation by ordinary citizens, and the invocations given — directly to those citizens — were predominantly sectarian in content."

The town had the support of 23 states, 119 members of the U.S. Senate and House, and the Obama administration. They noted that the tradition of legislative prayer began with the very first session of Congress.