The incident happened on 179th Street near 146th Road in Springfield Gardens.
Authorities say the officers are alert, conscious, stable, and talking to police officials at the hospital, but both needed surgery.
"Today, they saved that woman's life," Mayor Bill de Blasio said about the officers. "I want to be crystal clear, because these officers were there, that woman is alive."
Police say it started when a 41-year-old woman walked into the 105th Precinct Tuesday afternoon to report a domestic violence case.
At 12:40 p.m., two domestic violence officers then accompanied her back to the residence to collect her belongings.
Upon arrival to the home, the suspect, 41-year-old Rondell Goppy, was not present.
Shortly after, Goppy returned to the residence, walked in the door and began shooting at the officers.
Police say the officers shot back at the suspect. Goppy had three guns, one of which was found under his body, one of the officials said.
NewsCopter7 was over the scene:
Officer Joseph Murphy, 33, was shot at least one time in both hands and officer Christopher Wells, 36, in the leg. Fellow officers rushed the wounded cops to Jamaica Hospital.
"Both officers, nearly 14 years with the police department, and nearly six years with the police department respectively are awake and in stable condition here in Jamaica Medical Center," NYPD Commissioner Dermot Shea said.
Wells and Murphy required surgeries for their injuries.
Wells, a member of the NYPD since 2007, and Murphy, who joined the force in 2015, were both assigned to the 105th precinct, where the shooting took place.
At least one of the two police officers shot will be released from Jamaica Hospital Thursday morning.
The female victim was not injured, but the suspect was pronounced dead at the scene.
People were advised to avoid the area due to police activity.
Officials tell Eyewitness News the suspect had a history of domestic violence and that the home was the site of four prior domestic violence calls.
Goppy was a college security guard who had his guns taken away in July and returned in September. He was employed at the City College of New York in Harlem and was licensed to carry as a peace officer. The college's website lists him as a "Crime Prevention Specialist."
CCNY released a statement in regards to the incident.
"As there is an active investigation being conducted by the NYPD, what we can say is that The City College of New York community learned today that Specialist Rondell Goppy, a City College Public Safety Officer, lost his life in the course of an apparent domestic violence incident at his home in Queens. Any other questions would need to be directed to the NYPD."
MORE NEWS: 5-year-old boy mauled by dogs in Jamaica gets new lease on life with surgery in New York City
* More Queens news
* Send us a news tip
* Download the abc7NY app for breaking news alerts
* Follow us on YouTube
Submit a News Tip