Fur flew on the Upper West Side on Sunday evening, when FDNY rescuers shook a stray cat free from the tree where it had spent five long days after scampering skyward to escape a pit bull.

With a little prompting from firefighters in the bucket of a truck, the black-and-white city kitty — dubbed Tarzan by locals — went plummeting back down to earth and nearly into the arms of a waiting smoke-eater around 5:30 p.m., in a scene caught on video.

As onlookers’ reactions turned from gasps to cheers, the lucky furball quickly darted down West 89th Street away from the unwanted attention, apparently with all of its nine lives still intact.

Tarzan’s rescue capped a five-day saga that began when it scaled the 40-foot elm on Wednesday with a pit bull hot on its tail.

The feline’s refusal to come down both bemused and worried locals, who tried coaxing it down with food, leaving a ladder propped up against the arbor for it to climb down and attempting to scare it out of the tree with blasts from a water hose.