The contrast between her life and death could not be more stark: The beautiful, successful blond doctor, a married mother of three, found lying in the vestibule of a strange apartment building, underwear stashed in her handbag, dying of a likely drug overdose.

To her family and friends, Kiersten Rickenbach Cerveny had it all.

“This was so out of character . . . I know this was atypical,” one said.

“She was human,” another said. “People forget that because she was so perfect.”

Even those who didn’t know the 38-year-old Cerveny would likely draw the same conclusion.

One look at her Facebook page — since renamed “Remembering Kiersten Rickenbach Cerveny” — would have been, until last Sunday, enough to induce envy in most anyone.

Her photo album is vast. She was photogenic, well-loved, well-traveled. Here she is on April 5, 2008, celebrating “my 30th birthday in Turks and Caicos” with her handsome future husband, Andrew, also a dermatologist.

Here they are again, dressed up for a formal event, looking utterly carefree. “Wow!” posted a user. “What a good-looking couple!”

There are pictures of Kiersten sailing in Jackie O-style sunglasses, on vacation in Hawaii, partying in New Orleans, lounging après-ski in Whistler, swathed in a thick spa robe and, later, dining by the fireplace. There are photos of her three adorable, beaming children, the youngest now a little over 1 year old. She lived with her family in a $1.2 million home in Manhasset, LI, and her life — at least on Facebook — seemed to be filled with equally good-looking, happy people living equally privileged lives.

But then, these days, the gap between the person we are and the person we present to the world has never been wider.

Our web of lies

There are 80 million photos posted in Instagram a day. Facebook has 1.49 billion active users per month. Twitter has 316 million active accounts; Tumblr 230 million. Pinterest has 47.66 million unique visitors from the US alone and is the fastest-growing independent site in history.

Increasingly, most of us are living two lives: one online, one off. And studies show that this makes us more vulnerable to depression, loneliness and low self-worth.

In 2013, scientists at two German universities monitored 584 Facebook users and found one out of three would feel worse after checking what their friends were up to — especially if those friends had just posted vacation photos.

Even smaller details had the same effect.

“Overall,” wrote the study’s authors, “shared content does not have to be ‘explicitly boastful’ for feelings of envy to emerge. In fact, a lonely user might envy numerous birthday wishes his more sociable peer receives on his Facebook wall. Equally, a friend’s change in the relationship status from ‘single’ to ‘in a relationship’ might cause emotional havoc for someone undergoing a breakup.”

A 2014 survey conducted by the Manhattan-based marketing agency Current found 61 percent of millennial moms were rattled by the pressures of social media.

“There is an anti-social media movement on the horizon,” Current executive Amy Colton told Adweek. “Moms, especially young moms, are feeling pressured to present a perfect life . . . and starting to feel overwhelmed and annoyed.”

Mai-Ly Nguyen Steers, a post-doctoral fellow at the University of Houston, has spearheaded a similar study.

“The idea came to me when my little sister, who was 16, wasn’t invited to a school dance,” Steers, 38, tells The Post. “She told me about logging on to Facebook the very next day and seeing all these pictures of her friends at the dance, and that actually made her feel worse than not being invited.”

“Seeing Everyone Else’s Highlight Reels: How Facebook Usage is Linked to Depressive Symptoms” was co-authored with two other social psychologists and published in the Journal of Clinical Psychology last year. Steers cited the work of social psychologist Leon Festinger, who, in 1954, came up with “social comparison theory,” the idea that we measure ourselves in relation to others’ failures and successes.

Studies show young people, no matter how accomplished, are the most vulnerable.

Take Madison Holleran, a beautiful Ivy League student, star athlete and all-around popular girl. Her Instagram account only underscored this image: parties, friends, track meets, her dad cheering her on. But Madison was keenly aware of the difference between her online life and her real one. She once corrected her mother, who told ESPN The Magazine that after looking at Madison’s photos, she turned to her daughter and said, “Madison, you look like you’re so happy at this party.”

“Mom,” Madison said. “It’s just a picture.”

On Jan. 14, 2014, Madison posted a photo of trees strung with lights, bulbs glowing against the twilight. An hour later, she leapt to her death from the ninth floor of a parking garage.

She was 19 years old.

Her family has kept her Instagram account up as a reminder, especially for teens, that a life online may bear no resemblance to one actually lived.

One of Madison’s favorite quotes, posted to her feed a year before her suicide: “Even people you think are perfect are going through something difficult.”

Real and fake

Then there are those who aggressively seek out admiration and envy. Google “GoPro proposal” and you’ll get 428,000 hits — people who planned and recorded the moment they got engaged, then uploaded it for global consumption. Some couples live-stream it. Others stage-manage the “set,” then hire professional photographers to capture the moment.

“The engagement thing is so creepy,” says Chelsea Fagan, 26, whose website, The Financial Diet, covers the impact of social media on young women. “There’s this weird arms race now where everything has to be a moment, no matter how private. We always get a lot of responses with weddings and engagements — women spend a lot of money to look ‘Pinterest perfect.’ ”

It’s not just weddings or special events, though. Social-media users spend exorbitant amounts to look like their daily, everyday lives are spent eating the finest food, wearing the most on-trend designs, living a stylish, well-appointed life — no problems.

Fagan recently ran a post titled “My ‘Perfect’ Life on Social Media is Putting Me in Debt.” The author went only by the name Jasmine. She wrote that “my ‘real’ life is actually pretty boring,” but her 5,000 followers would never know it.

“I have a side of my apartment that I photograph, and it’s perfect. The other side is always a mess,” she wrote. “I buy a lot of things to maintain my image . . . I even consider it important to always have a fridge full of La Croix and coconut water for my pictures. Writing this makes me realize just how insane it all is.”

Jasmine confessed that she’s $3,400 in credit-card debt.

“When your life feels perfect, or like a catalog, that’s aggravating to people,” Fagan says. “We’re hearing a lot of pushback.”

One of last year’s most popular viral videos, with more than 10 million views, was a short titled “What’s on Your Mind?” Produced by three Norwegian brothers, it’s a black comedy about one young man’s actual life (broke, dumped, unemployed, drinking alone and paying for sex) versus his online one (Single! Free! Out clubbing! Living the dream!).

“I just saw one status update after another,” said director Shaun Higton, explaining the film’s genesis. “ ‘This is my new girlfriend — yay!’ ‘This is my new car — yay!’ ‘I’m going on vacation — yay!’ I was just like, ‘Ugh, gosh, when does it stop?’ Like, everybody can’t be having a great day today. And I was feeling bad about my own life . . . I think we’ve all been there.”

Artist Zilla van den Born was similarly inspired. Last year, she uploaded a monthlong series of photos taken on her travels in Southeast Asia — scuba diving, praying in a Buddhist temple, sampling local cuisine — then revealed those images were all the work of Photoshop. She had hidden in her apartment the entire time, duping even friends and family.

“My goal was to prove how easy it is to believe in a distorted reality,” van den Born told The Washington Post. “I wanted to make people more aware that the images we see are manipulated, and it’s not only the models in the magazines but also our friends on social media who contribute to this fake reality. We should be more careful about what we believe, and ask ourselves why a photo is made — how and by whom and with which intention.”

I think people are becoming more comfortable with the idea that what you post on Instagram isn’t really you. - Chloe Miller, 16

“Finstagram” is yet another response to such pressure. Popular mainly with young women who feel pressure to always be photo-ready, “Finstagram” is a fake Instagram, or second account — which, ironically, is the more truthful of the two, and accessible only to close friends. The one everyone sees, the real Instagram, or “rinsta,” is the acknowledged fake.

“My rinsta is the filtered me,” one 19-year-old told Elle magazine last July. “It’s where I look good in my pictures, I’m happy, and I’m having fun. My finsta also shows that, sometimes even more than my rinsta because it’s so genuine, but it also shows me sad, scared, drunk or embarrassed.”

And for those legit photos, there’s always digital retouching. “You can literally airbrush your pictures online for free,” Chloe Miller, 16, told NPR. “I know; I’ve done this. You upload your picture and you can take out all your little pimples and stuff to make it look like your skin is perfect, your hair is perfect.”

Five months ago, The Financial Diet’s Fagan launched #TotalHonestyTuesday. It’s a hit with her audience, thousands of whom post screenshots of everything from facial blemishes to cellulite to credit-card bills.

“People find it cathartic,” she says. “I think people are becoming more comfortable with the idea that what you post on Instagram isn’t really you. It’s a fictional version of you.”

https://instagram.com/p/5-Mm_9PrFJ/?tagged=totalhonestytuesday

A hidden life

Was the same true for Kiersten Rickenbach Cerveny? It’s possible her friends and family, still reeling from her death, will never know.

On Oct. 3, after telling her husband she was going into the city for a girls’ night out, Kiersten met up with friends at a hotel at 6:30 p.m. The group then went drinking on the Lower East Side. They were out till 2:30 in the morning, drinking hard and allegedly using cocaine.

At 3 a.m., Kiersten peeled off with Marc Henry Johnson, a 51-year-old producer for HBO. She had known him since 2009 — 10 months before she married for the second time.

By 4 a.m., they were in a cab on the way to Chelsea, and the two went up to the cabdriver’s apartment.

Kiersten’s body was found at 8:30 that morning, sprawled in the vestibule, her feet propping the door open. Video showed Johnson and the driver dragging her body down the building’s stairs, leaving her to die alone.

Johnson was questioned by police and is not expected to face charges.

A family friend says that Kiersten’s first husband, also a doctor, is “utterly distraught” and that no one saw this coming.

“She was a ray of sunshine and did a lot of charity work,” she said. “Who hasn’t gone off her rocker?”

Yet Karina Freedman, a skin care specialist with a large clientele in Kiersten’s Manhasset neighborhood, says many of these women are, in fact, leading double lives.

“So many of the husbands work late hours and their wives are home alone,” she tells The Post. “So, on weekends, it’s common for them to go out to bars and clubs in the city without their husbands. Many of the women in Manhasset are partiers.”

But you’d probably never be able to tell online.

Additional reporting by Beth Landman