The CIA used a new technology tool called "Ghost Murmur" to locate and rescue the second American pilot shot down in southern Iran, The Post has learned.

The secret technology employs long-range quantum magnetometry to detect the electromagnetic signature of a human heartbeat and links the data with artificial intelligence programs to isolate this signal from background noise.

This was the first time the spy agency had deployed this tool in the field.

"It's like listening for a voice in a stadium, except the stadium is the desert," a source told The Post. "Under the right conditions, if your heart is beating, we will find you."

Ghost Murmur was developed by Skunk Works, the secret advanced development division of the aerospace giant. The technology has been successfully tested on Black Hawk helicopters for potential future use on F-35 fighter jets.

The missing and injured weapons systems officer, publicly known only as "Dude 44 Bravo," was hiding in a mountain after his F-15 was shot down last weekend, surviving two days in barren terrain as Iranian troops scoured the area for the American with a bounty on his head.

The desolate landscape created "an ideal opportunity for the first operational use" of Ghost Murmur, said one of the sources.

"Normally the signal is so weak it can only be measured in a hospital setting with sensors placed almost on the chest," the source said. "But advances in a field known as quantum magnetometry, particularly sensors built around microscopic defects in synthetic diamonds, appear to have made it possible to detect this signal at much greater distances."

It is unclear whether this technology could have other uses during warfare.