Two children, aged 8 and 10, were killed and 17 people were injured when a gunman fired through the windows of a Minneapolis Catholic church at people celebrating Mass, police said.

The shooting occurred when Annunciation Church, which also houses a school, was filled with students. Of the 17 people injured, 14 are children and seven of those shot are in critical condition.

Authorities said the gunman, identified as a 20-year-old male with no "significant criminal history", also died from a self-inflicted gunshot.

"This was a deliberate act of violence against innocent children and other people worshipping," Police Chief Brian O'Hara told reporters.

"The sheer cruelty and cowardice of firing into a church full of children is absolutely incomprehensible," he said.