30-year-old Freddie Perez and 25-year-old Tavon Thomas have been charged with the murder of 2-year-old Nikolette Rivera.
Police said Perez has 17 prior arrests, 11 of which were for narcotics violations. Thomas has nine prior arrests.
Police believe 29-year-old Francisco Ortiz supplied the two men with the deadly weapon, an AK-47 assault rifle.
Police have charged Ortiz with attempted murder for shooting 11-month-old Yazeem Jenkins, in Philadelphia's Hunting Park section on Saturday.
Surveillance video shows two gunmen firing at an SUV on Clearfield Street in Kensington on Sunday afternoon, less than 10 minutes before Nikolette Rivera was fatally shot in the back of her head while in her home.
Police said both of these shootings were drug-related. The motive appears to be for control of narcotics territory and its distribution in the area, police said.
"Both of these cases are horrific demonstrations of how dangerous the drug trade is in the city of Philadelphia. Drugs and violence go hand in hand," said Anthony Voci, chief of the homicide unit in the Philadelphia District Attorney's Office.
Ortiz was arrested Thursday after appearing in court for another open gun-related case. Investigators said Ortiz was released from prison in January after serving a 10-year sentence, and he is also a prime suspect in a domestic-related homicide from September 18.
All three men have an extensive record, and are believed to have been targeting the children's fathers in drug deals gone bad, police said.
"Some of the parents of these two children are responsible for the death and for the severe injuries that were caused to their children. They engaged in narcotics behavior, narcotics transactions, narcotics operations, they put their children in harms way," Voci said.