A Carlstadt man fatally shot his wife on the lawn of their home Wednesday evening, leading to a tense standoff in which local police helped his children escape unharmed before the man’s body was found hours later inside in a foyer of the house, authorities said.

Scott Sabia, 45, killed himself sometime after he retreated into his home at 505 Union St. when police arrived at 6:19 p.m., Bergen County’s acting prosecutor, Gurbir S. Grewal, said in a press conference.

Grewal said that the standoff ended after 10 p.m. when a SWAT team, which had surrounded the house hours earlier, went inside and found Scott Sabia’s body, which had a gunshot wound. Grewal said that police had been trying unsuccessfully for about an hour to contact him. Earlier in the night, Grewal said that a suspect had barricaded himself in the home.

Witnesses said they saw the SWAT team members open a door to allow a bomb squad robot into the home at one point.

The home belongs to Scott and Michele Sabia, according to tax records, and neighbors said the couple, who had recently gotten back together after a separation, lived there with their three children, two sons and a daughter.

At 9:30 p.m., Grewal said the children were all safe and that a female had been shot in what he described as a homicide. It was not clear whether authorities were in contact with the suspect.

Grewal did not initially identify the man who was inside the home or the woman who had been shot. But the SWAT team called to Scott Sabia by name in the course of a standoff.  “Scott, this is the Bergen County SWAT team, come out with your hands up,” a police officer said through a loudspeaker about 8:30 p.m.

Grewal did not immediately provide details about what led police to the home. Shortly after 8 p.m., he said the situation was “fluid,” and that he was waiting to receive an update. “I know there’s a situation,” Grewal said at the time. “I haven’t gotten an update.”

He said a SWAT team was at the scene “rendering it safe” but that he would not have details until later in the evening.

Scott Sabia listed himself as being “separated” on his Facebook page, but a neighbor said the couple recently got back together. Michele Sabia was a teacher in Rutherford, according to neighbors and state records.

One neighbor, Laura Torres, called Michele Sabia “a lovely Christian woman.” She said the couple had a 9-year-old daughter and two sons, 11 and 14, the oldest having just graduated from eighth grade. The couple separated last year, she said, but had gotten back together.

Scott Sabia posted numerous items about depression and mental illness on his Facebook page. Torres said he had fought a long battle with depression, and at times he had been unable to get out of bed.

Another neighbor, Mike Kara, said he often saw Scott Sabia outside playing with his children. “It’s a nice neighborhood,” Kara said. “I never before saw something like this in the neighborhood.”

Scott Sabia’s parents, who live nearby, were sitting outside a neighbor’s home where people walked up to them and told them they needed to be strong for their grandchildren. Neighbors said the Sabia family had lived in the area a long time and was an important part of the community.

On his Facebook page, Scott Sabia posted photographs of apparently happy family outings at the Jersey Shore and in Lancaster, Pa., where, he posted, “I’d love to live!”