The Royal Canadian Mounted Police said they have recovered remains from some of the destroyed homes. Earlier, authorities had said at least 18 people were killed in the 12-hour attack.
Officials said the suspect, identified as 51-year-old Gabriel Wortman, was shot and later died on Sunday. Authorities did not provide further details or give a motive for the killings.
The dead include a 17-year-old as well as a police officer, a police news release said. All the other victims were adults and included both men and women. There were 16 crime scenes in five different communities in northern and central Nova Scotia, it said.
"Some of the victims were known to Gabriel Wortman and were targeted while others were not known to him," the police statement said.
Authorities also confirmed Wortman was wearing an authentic police uniform and one of the cars he used "was a very real look-alike RCMP vehicle."
"This is an unprecedented incident that has resulted in incredible loss and heartbreak for countless families and loved ones. So many lives will be forever touched," the police statement said.
In an earlier news release authorities had said they believed there were 23 victims, but Royal Canadian Mounted Police spokesman Daniel Brien later clarified the death toll included 22 victims and the gunman.
As fears mounted that more dead would be found in burned out homes, a young man said Tuesday that his grandparents were missing and believed dead after their log cabin was set ablaze during the attack.
Justin Zahl told The Associated Press he finally heard from police after frantic calls for information and seeing images of his grandparents' home in the rural town of Portapique burned to the ground, with their cars in the driveway.
It was not immediately clear, however, if they were among the remains police said were found.
Police teams were spread out across the 16 crime scenes including the neighborhood where the rampage began late Saturday on Portapique Beach Road, where the suspect lived.
Police have warned the death toll will almost certainly rise as investigators comb through homes destroyed by fire.
Zahl said he last heard from his grandmother early Saturday evening via iMessage on her iPad.
"They were angels," he said, adding that the couple were like parents to him and his 19-year-old brother, Riley. "He was the smartest man I knew, and could hold a conversation with anyone," he said of the grandfather.
He said John Zahl, in his late 60s, and Elizabeth Joanne Thomas, in her late 50s, lived in Albuquerque, New Mexico, before retiring to their dream home in Nova Scotia in 2017 after falling in love with the place on a visit. Justin and his brother lived with them for a while but both young men no longer do and neither was at the home during the attack, he said.
Authorities said Wortman made his car look like a Royal Canadian Mounted Police cruiser allowing him to travel easily within a 30-mile (50-kilometer) area.
As the attack ensued, police warned residents in Portapique to lock their doors and stay in their basements. The town, like all of Canada, had been adhering to government advice to remain at home because of the coronavirus pandemic, and most of the victims were inside homes when the attack began.
But no wider warning was issued, and questions emerged about why a public emergency alert was not sent province-wide through a system recently used to advise people to maintain social distancing. Police provided Twitter updates, but no alert that would have automatically popped up on cellphones.
"There should have been some provincial alert," said David Matthews, who said he heard a gunshot while walking with his wife Sunday. Shortly after they returned home, their phone started ringing with warnings from friends that there was an active shooter in the neighborhood.
Several bodies were later found inside and outside one house on Portapique Beach Road, police said. Bodies were also found at other locations in Nova Scotia and authorities believe the shooter may have targeted his first victims but then began attacking randomly as he drove around.
Authorities said Wortman did not have a police record, but information later emerged of at least one run-in with the law.
Nova Scotia court records confirm he was ordered to receive counselling for anger management after pleading guilty to assaulting a man in the Halifax area on Oct. 29, 2001. The guilty plea came on Oct. 7, 2002, as his trial was about to begin.
He was placed on probation for nine months, fined $50 and told to stay away from the man, and also prohibited from owning or possessing a weapon, ammunition or explosive substances.
Royal Canadian Mounted Police Commissioner Brenda Lucki said police were still determining what weapons were used in the attacks.
Cheryl Maloney, who lives near where one victim, 54-year-old Gina Goulet, was killed, believes she was likely saved by a warning message Sunday morning from her son that read, "Don't leave your house. This guy is at the end of your road and he's dressed like a cop."
"I really could have used that provincial warning, as I walk here all the time and I've been in the yard all week," she said.