Nupur Dave By all accounts, including her own, Nupur Dave had the dream life.

A native of India, she had spent the past decade living in the US. She was working at Google at the perk-filled "Googleplex" headquarters in Mountain View, California, at a job she loved. And she had obtained permanent residence, her green card.

She was a program manager for a part of Google called Network Content Distribution, the network tech that makes Google run faster (in geek speak: it's Google's homegrown alternative to a content distribution network like Akamai).

And the opportunities for promotion were plentiful.

"I got to travel all over the world, attend conferences," she told Business Insider."It was great. The team was great. It was really good job."

There was just one problem. She was growing increasingly unhappy with this Silicon Valley dream life.

Expensive and lonely

For one thing, the cost of living was a hardship. While she was paid well, it wasn't enough to get ahead in the costly Bay Area, much less buy a house.

The idea that all Googlers are wealthy is a "myth," she told Business Insider. While a highly specialized software engineer or a high performance manager are definitely well compensated (some of them make seven figures between pay and stock), for many rank-and-file Google employees, "Google is a medium payer," she said.

For instance, salaries for a technical program manager at Google range from $93,837 to $176,500, according to Glassdoor. While that's not chicken scratch, when you factor in what it costs to live in the Valley, those salaries don't go far.

"I always rented," she said, and she often had a roommate, too.

But money wasn't her main problem: loneliness was worse. She missed her family in India. She missed her home country. She was single. Working long hours for Google made it hard to meet someone and have a relationship, she said. And while there is social prestige in the Valley attached to being at Google, it also intimidated some men, she felt.

She became very involved with the Indian Google Network. Google has a large contingent of India ex-pats (including CEO Sundar Pichai) in Mountain View, and the Indian network is one of many Google diversity groups.

Henry Blodget / Business Insider "I founded the Women’s Cricket team at Google. And with the India Google network, I organized a lot of events. I had a life. I really had a lot of friends, I’m a very social person," she said.

It didn't stop that nagging feeling, though.

At one point, Dave tried shaking up her life by moving to the trendy city of San Francisco. Walk everywhere. Great food. Gorgeous views.

But that soon became exhausting. She wound up with a three-hour commute, getting home each night at 8:30 p.m. She hired help from TaskRabbit to do the cleaning and the chores. But her rent was higher, as were other costs, and she couldn't afford it at the level that she needed.

"I was becoming sadder and sadder," she said. The exhaustion of living in San Francisco also meant less time to do her hobby, writing and photography for her recipe blog.

Then, during a visit home for her cousin's wedding, she was talking with her 8-year-old nephew who asked her why she lived in America. The only answer she could think of was, "Because my job is good."

Less pay, more ... everything

Was she really living for a job? Could she have both? A life near her family in India and Google? She searched for and landed a Google job in India of parallel responsibility as a Technical Program Manager for Google For Work. But it involved a big pay cut.

Allison Joyce/Getty Images She didn't decide to take it until she had a conversation with a stranger on a plane ride who happened to be a PhD from MIT in economics and a law professor. He told her the Google India job could have a big and helpful economic impact for her home country. And the salary was enough for her to buy her own house in India.

It's now been seven months and she says she's way happier. "My stress levels have been reduced to one tenth what they were. I used to sleep for 5 hours a night in the U.S. In India, I sleep for 8 hours now," she says.

She wrote a post about leaving America for India that went viral on LinkedIn and has since received thousands of messages from people.

Her advice to other U.S. immigrants is "don’t torture yourself" but to "trust your gut." It will tell you if the U.S. is your true home, or if it "is not your destiny."