This story appears in the September 2018 issue of National Geographic magazine.

Several years ago, on assignment for National Geographic, I ventured inside a cave in Uganda to photograph a roost of roughly 100,000 Egyptian fruit bats. The bats are common throughout Africa, but this cave was special—shaped like an arch with light shining in at both ends. The rock ceiling was low, which meant the bats would be close and the shooting relatively easy.

View Images NGM MAPS

I wore a respirator as a precaution. The only real danger, I thought, would come from the pythons and forest cobras slinking across the cave floor as they hunted for downed bats. I would be fine if I just watched my step. Or so I thought.

After working for a few hours, I exited the cave at dusk, packed up my gear, and began the long hike back to the road with my guide. I was filthy and tired but excited about the images I’d just taken and the fact that the bats didn’t seem to mind my being there.

A hundred steps away from the cave, I’d just taken off my respirator and glasses when I heard a tremendous mechanical clamor above my head, the sound of a thousand windup toys all going off at once. Then came an ammonia-laced gust of wind as the bats in the cave poured up and out into the gloaming to begin their nightly foraging.

I looked up, just for a second, and caught a juicy dollop of fresh guano directly in my left eye. It was hot, and it burned. I knew right away this was a “wet contact,” potentially as dangerous as a bite.

View Images For a story on the wildlife of Africa’s Albertine Rift , Joel Sartore photographed Egyptian fruit bats roosting inside a Ugandan cave. When he left the cave at the end of the day and removed his protective gear, he risked his life with one glance to the sky. Photograph by CHARLES RASH

I’ve photographed animals for decades, and I know the drill: It’s not the bears or lions that get you; it’s the little stuff. I’ve had botfly larvae bury themselves in my hands and lower back. Then there was mucocutaneous leishmaniasis, a disease caused by a flesh-eating parasite. That one required a month of chemotherapy. My parents, of course, lived in absolute fear every time I went to the tropics.

Back at camp I immediately called the Ugandan arm of the U.S. Centers for Disease Control and Prevention to see if the agency knew what, if anything, these bats might be carrying. There was a long pause on the other end of the line. “You shouldn’t have gone in there,” said the man. “Marburg circulates in that cave.”

The Marburg virus is a terrible, messy death. It causes a hemorrhagic fever (translation: you bleed, everywhere) that’s similar to that from Ebola (only it kills you a little faster sometimes).

There’s no easy way to test for Marburg. If I was infected, the symptoms would arrive in three days to three weeks: severe headache, organ failure, and a raging fever so bad I wouldn’t remember much—if I lived. In some outbreaks the death toll has been as high as 90 percent. My odds of survival would likely improve in the United States. “Go home now,” the man said, “before you have any chance of becoming contagious.”

Once back in Nebraska, I went into quarantine inside my own house, in a small attic bedroom that overlooks the street. For the first time I thought relentlessly about death. I remember it being sunny outside, the birds singing, the garbage truck roaring through the neighborhood. Every day like clockwork my dog barked at the mailman. Indeed the whole world acted as if nothing at all was wrong. I thought, Don’t they know what’s going on in here? Of course not. If they did, it would make national news.

For three weeks I stayed away from my family. I watched my daughter’s birthday party from across the hall. I found my meals on a tray outside my door. I didn’t eat much though. I just sat and thought, Do I feel hot? Does my head hurt? Yes? Maybe? Maybe not? I took my temperature 50 times a day. At the slightest hint of a fever, I was to drive myself immediately to the nearest hospital, just two miles away, where they had a negative-air-pressure room (to keep the virus from getting loose) all set up with my name on it. Inside that room, I imagined, there would be a negative-air-pressure tent surrounding my bed to seal me in even further.

Up until now this assignment on the wildlife of Africa’s Albertine Rift had been a thrilling ride. We’d put camera traps on water holes and carcasses, capturing images of hippos, hyenas, and leopards from just inches away. I’d watched vervet monkeys steal the food right off my dinner plate. I’d been charged by an elephant, a lion, and a mountain gorilla—my fault, of course, for trying to get just a little closer.

But that was then, and a world away. Here in Lincoln, Nebraska, the time crawled by in my little room. I remember removing a clock because it ticked too loudly, another heartbeat I didn’t need. I wondered if my photos were good enough. I wondered what photos I’d missed by not staying in Uganda until the end of my assignment time. But more than that, I wondered if, once I was out of the woods, I would appreciate all that I’d been given: my family, my life, and the absolute privilege to try to save the last wild places using photographs—something I still can’t believe I’ve been able to do for a living.

On Day 22, with the quarantine over and no sign of sickness, I could finally emerge. I sat down at my own dinner table for the first time since leaving for Africa. My wife, Kathy, and all three of our kids were there, preparing a special meal to celebrate the end of my quarantine. Then someone turned on a blender.

Just for a moment, the room was filled with the sound of a thousand bats taking flight. I closed my eyes tight, just in case.