Police on Monday did not publicly identify any of the victims at the Abundant Life Christian School, a private institution that teaches some 400 students from kindergarten through 12th grade.
At least six other people were wounded, according to police. Two students had life-threatening injuries; four other people had injuries that were not life-threatening.
The shooter, a student at the school who used a handgun, was found dead inside the school by officers who immediately entered campus upon arrival, police said. They declined to identify the shooter by name, age or gender.
No officers fired their weapons, police said.
There was as yet no known motive for the violence, which authorities said took place in one space inside the school. The shooter's family was cooperating with the investigation, police said.
Madison Police Chief Shon Barnes, a former public school history teacher, said the shooting took place just before 11am on Monday.
"Today is a sad, sad day, not only for Madison, but for our entire country, where yet another police chief is doing a press conference to speak about violence in our community," Barnes told reporters.
"Every child, every person in that building, is a victim, and will be a victim forever. These types of trauma don't just go away," Barnes said.
There have been 322 school shootings this year in the US, according to the K-12 School Shooting Database website. That is the second-highest total of any year since 1966, according to that database - topped only by 2023's total of 349 such shootings.
With AAP.