Your #1 priority: taking care of yourself
It's an issue of priority, not an issue of importance
Taking care of others (and your relationships with them) is important. Taking care of yourself is important. Both are important.
But in creating the best possible relationships with others, we need to use attitudes, structures, understandings, and methods so that taking care of ourselves and taking care of others is always win-win; both sides are better off from the relationship and the "transactions" that occur between them.
When priorities are not needed
Priorities are not an issue as long as relationships and transactions are set up and maintained to be mutually beneficial (as judged from both sides). Examples:
Buyers and sellers both agree that a transaction will not occur unless each feels that they will be better off with the exchange.
Friends enjoy a visit together; each one feels their life is happier/enriched by their time together.
A parent and child enjoy their relationship with each other; each feels the added value by having their relationship and their mutual contribution to each other.
A couple live, share tasks, and commune together. Each is clear of the value provided by their partnership.
It is only when a conflict or potential conflict occurs that we must remain aware that our #1 priority is to take care of ourselves (short-term and long-term).
Your friend asks to borrow some money. Will you be taking care of yourself and your relationship if you say "yes"?
You want to eat out and your spouse wants to stay in. If you agree to stay in, will you still be taking care of yourself? Or will you feel any resentment or toleration in doing so? Can you find a third option that both of you are happy with?
You want to take a year's sabbatical and travel the world. Your family thinks you're crazy. What to do?
You want a divorce, but your spouse is fighting you tooth and nail. And you're concerned about how it will affect your children. How can you take care of yourself and them too?
You ask for a raise. But your boss refuses. What to do?
You see a request to "adopt a child" in a slum area of Bangladesh to help the child with some clothing and schooling costs. Can you feel happy about doing this so that you're taking care of yourself?
Many seeming conflicts can be resolved by considering the long-term as well as the short-term. But sometimes, even with long-term thinking and creativity, it may still come down to, "Do I take care of myself or do I take care of them. I don't see a way to do both." This is when you need to choose courage to prioritize taking care of yourself (just as it's their #1 responsibility to take care of themselves).
Why is taking care of yourself a higher priority than taking care of others (when a choice must be made)?
You are the only one who's most likely to know what's best for you; you've got "local" knowledge that no one else can have as clearly are you do. Even if someone else has dedicated themselves to taking care of you, unless you're in a coma, it's a responsibility you can never give completely away.
If you prioritize taking care of another (at the expense of yourself), you will weaken your ability to take care of others in the future. So, long term, others will likely suffer more when you prioritize taking care of them in the short-term. (As the airlines day, "Put your mask on first."). Also, almost always, we damage the quality of our relationships with others when with prioritize their life over ours. We shut down, we get impatient, we feel resentment, and/or we end up tolerating our relationship.
Why do we have such problems to prioritize taking care of ourselves?
Our world culture (I don't know of a single culture that is not included) moralizes thinking of others first as the good thing and being selfish as ethically questionable.
Just listen to our language. Words that lionize:
Hundreds of words lionize taking others into consideration: generous, considerate, warm-hearted, affectionate, altruistic, charitable, compassionate, concerned, cooperative, dependable, dutiful, faithful, loyal, forgiving, good-hearted, honest, humane, humanitarian, neighborly, open-handed, polite, punctual, reputable, self-sacrificing, selfless, thoughtful, unselfish, just to name a few.
Words that pejoratize:
Every single word in the English language that indicates that one might be prioritizing taking care of oneself over taking care of others has a pejorative connotation. To name a few: antisocial, arrogant, avaricious, sinner, slut, thief, betrayer, boastful, brutal, careless, cold-hearted, conceited, controlling, criminal, deserter, dishonest, disobedient, disrespectful, egotistical, greedy, hard-hearted, inconsiderate, intolerant, mercenary, neglectful, opportunist, possessive, self-seeking, selfish, thoughtless, wasteful, unkind, to name a few.
When some my clients have objected to me using the word "selfish" as a positive word, I asked them, "Can you think of any single word in the English language that means, 'concern for one's own interests' that has a positive connotation?" They can't. So unless I coin a new word, which I've decided not to do, we need to rehabilitate the word selfish.
This good/bad paradigm runs deep in our upbringing and culture
Even my mother (and my father) suffered deeply from it. In most areas, my mother was pretty good about taking care of herself. She would quip, "If someone calls me selfish, it doesn't bother me. But I get defensive if they call me stingy."
My mother told me (years after she divorced my father), that she suspected she had made a mistake in marrying my father within two days of their wedding. But she believed in persistence (another one of those words that are lionized, as in contrast with quitting, which is pejoratized). So she stayed married to a man she didn't love and didn't respect for 41 years, until she finally choose the biggest courage of her entire life to leave him. She was going to leave him five years earlier, but when she told her mother about her plan, her mother said, "Dorothy, you can't leave him. He needs you." She stayed five more miserable years in a marriage because of her fear of her mother's (and maybe others') blame or disappointment.
In order to leave him, she told me she had to hate him. She had to remember all the "bad things" he did. Otherwise, she told me, she would feel too sorry for him. She continued to hate my father until her death in at age 90 in 2012 (my father had died many years earlier in 1991).
These are the wages of being dominated by a culture that prioritizes taking care of others over taking care of yourself.
Ultimately it gets down to choosing courage
Yes, it's important to do what we can to create and maintain a mutually selfish relationship with others in our life (even if it's with a taxi driver whom we're unlikely to see again). And it makes sense to make more efforts towards creating mutual selfishness in longer and/or closer relationships.
But, ultimately, you may need to prioritize your selfishness (considering both short-term and long-term) over theirs. Acting on that can often be a choice of courage.
Another or others may blame you or be disappointed in you. See undoing fear.
You may even anticipate blaming yourself (the purpose of which is to beat others to the punch). See undoing guilt.