An upstate New York millionaire celebrating his 65th birthday in Costa Rica plummeted 100 feet to his doom while propelling down the side of a treetop restaurant.

John Anderson, of Pittsford, NY, fell to his death Saturday while at a rainforest restaurant, which offers diners the unique experience of rappelling down to the ground after their meal, the Democrat and Chronicle reported.

“He wasn’t on a rappelling adventure, he was just getting back to the ground,” said the man’s business partner, James Ryan Jr. “There’s a safety system but for whatever reason that didn’t work.”

The father of four was having a birthday dinner with friends at The Pacuare Lodge in the “Nest,” where guests zip-line onto a platform among trees high above the jungle floor for dinner.

A two-night stay at the “eco-lodge” can set guests back upwards of $1,880, according to their website.

Costa Rican authorities are investigating the incident, Ryan said.

A native Long Islander, Anderson was co-owner of Ryco Management, a property management company, and before that, was CEO of Willmorite, where he oversaw construction and property development.

He also taught real estate finance at the University of Rochester, where he was an alumnus.

“John was really well respected,’’ Ryan said. “In many ways, he was private and not a person that everybody knew in that sense as a business leader. But he was an incredibly reliable partner and trustworthy. Just a very honorable person, especially in his business relationships.’’

Funeral arrangements are pending.