Hours after the ruling, Ms Palin, who is reportedly considering running for president, Tweeted: “Common sense & decency absent as wacko ‘church’ allowed hate msgs [email protected] soldiers’ funerals but we can’t invoke God’s name in public square”.

Yesterday, the court voted 8-1 in favor of the church, based in Topeka, Kansas, which has demonstrated at thousands of military funerals across the US, declaring that the deceased are examples of God punishing America for the country’s tolerance of LGBT people.

Justice Samuel Alito was the sole dissenter in the case of free speech versus privacy rights. He argued the First Amendment did not protect Americans indulging “vicious verbal attacks that make no contribution to public debate” during “a time of intense emotional sensitivity.”

The majority of the court ruled that the protests, while insensitive, are protected under the Constitution.

Ms Palin was quickly criticised for her apparent about-face on the issue, given her history on gay rights and her fierce defence of the First Amendment, which she invoked last year after David Letterman had make fun of her and her daughter on his show. She said: “Letterman certainly has the right to ‘joke’ about whatever he wants to, and thankfully we have the right to express our reaction.”

Also following the decision, members of Westboro pledged to “quadruple” their presence at military funerals. Albert Snyder, who sued the church after they protested at his son’s funeral told the New York Daily News: “Nobody’s going to sit here and tell me that this is what our forefathers meant by free speech.

“[If] they’d have done this to soldiers back during our forefathers’ time, they probably would have been lined up and shot for treason.”