By Susan Guyett

INDIANAPOLIS (Reuters) - Democrats gained a U.S. Senate seat in Indiana that had been in Republican hands for decades after the Republican candidate blundered by calling pregnancy from rape something God intended.

Democratic Congressman Joe Donnelly beat Republican state treasurer Richard Mourdock Tuesday. The seat is currently held by Republican Senator Richard Lugar, who lost a bruising primary to Mourdock this past spring.

Donnelly is considered a moderate, anti-abortion Democrat. He voted for President Barack Obama's health reforms but does not always vote with Democrats.

The outcome is a severe blow to Republicans, who needed a net gain of four seats to take a majority in the U.S. Senate.

Support for Mourdock fell after he said in an October 23 debate that pregnancy resulting from rape was "something God intended to happen." Mourdock said rape should not be an exception to the abortion ban.

Other remarks by Republican candidates on rape also have stirred controversy. In Missouri, Republican senate candidate Todd Akin prompted an uproar by saying women's bodies have defenses against pregnancy after "legitimate rape."

Mourdock also was hit by Democrats attacking his "extreme" Tea Party movement views - lower taxes, fewer regulations and massive spending cuts - plus his televised remarks after the primary that "bipartisanship ought to consist of Democrats coming to the Republican point of view."

"Mourdock didn't help himself after the primary by taking a very hard line," said Marjorie Hershey, a politics professor at the University of Indiana.

Mourdock's strong conservative base enabled him to defeat Lugar, first elected in 1976, in the Republican primary.

Lugar was re-elected repeatedly with the help of Democrats and independents who admired his record of bipartisanship and foreign policy expertise that included helping to decommission some of the nuclear weapons of the former Soviet Union.

One factor that may have helped Donnelly is that Lugar has stayed away, telling an Indianapolis blogger in September: "I have not been a factor in the campaign, and I do not intend to do so."

Donnelly will be the first Democratic U.S. Senator from Indiana not named "Bayh" since Vance Hartke left office in 1977; Democrat Birch Bayh was in the Senate from 1963 until 1981 and son Evan Bayh held the seat from 1999 to 2011.

(This story corrects "Republicans" to "Democrats" in paragraph 3.)

(Reporting By Susan Guyett, David Dawson and Nick Carey; Editing by Mary Wisniewski, Greg McCune and Ciro Scotti)