TL;DR: It's a hard problem. Be the best communicator you can. Be a good listener. Recognize and set healthy boundaries. Remain calm, proactive, not reactive, use something like meditation if it helps. Watch what you say, filter what you know would upset the other person; it is possible to turn potentially offensive phrases around in a self-deprecating way.
Well firstly, we will react stronger to things presented as conflict or problems with people closest to us merely because we are more emotionally invested with that person. It doesn't matter how minor or serious the topic, we invest more. Secondly, it is common that those closest too us have grown up seeing examples of adult behavior that show it's somehow okay to show less courtesy, tact & boundaries in what we say & how we say it to those we are close to. I am not sure I really understand why this is and I know from having friends from other cultures/countries, and from reading, this is a cross-cultural thing. For some reason, if family doesn't like something, even if it doesn't really impact them, they are far more likely to feel bold enough to comment about it than a stranger or even a friend would, although some friends will too.
We have to remind ourselves often that we only control our own behavior, as you said. I also think we can have some influence on whether a conflict arises based on that alone. Since we are only one component though, and conflict occurs between two or more people, we can only account for our portion of that. You can control your portion in part just by learning how to be the best communicator you can, which means you have to actually research & learn how to effectively communicate your thoughts, feelings, needs & wants with those around you. There are lots of resources to assist. This is a a good starter one & you can get the free audio on "Crucial Conversations" here.
I have read many books on communication, because I add to it as needed. When I became a parent for instance, I then delved into reading more on how to communicate better as a parent. It should always be paired with learning to be a truly effective listener as that is as important as being clear in what you say.
Learning skills on how to understand & recognize healthy boundaries is also crucial. This will be absolutely critical to a more peaceful relationship if you haven't been taught through example what healthy boundaries are & how to set them. It has helped my life tremendously to learn boundary significance & how to set them & respect them. Here is a book on Amazon.
And the last component for me in learning how to build better relationships has been a lesson with meditation. I am sure what helps each person most is entirely personality based. You just need to find what you feel best helps you to learn how to calmly respond to difficult situations. It is generally easier to remain calm & level if you are the one bringing up the issue, not always, but often. The reason for this is that you knew the conversation was coming. When something comes up you don't see coming or didn't select timing, learning how to mediate your reaction is harder as you have no preparation time mentally/emotionally. So meditation helped me to learn how to stop & breathe before I respond to things. I used to be far more reactive to life. I was able to gain more skills, through meditation, on how to live more proactively. Now I am not claiming I do this perfectly nor do I claim meditation is the only way or best way for all people. I can simply say it's tremendously better than it was & my hope is that it is something I can continue to improve on all the time. It is part of maintaining the control we all want over our own self, our feelings, our lives. If we do not learn to control our responses, we are at the mercy of others all the time (as in, they are able to change our mood, our feelings, etc at will, by their behavior) then we essentially are giving away all of our personal power, our control.
The books I linked are just ones I happen to know are pretty good. There are a multitude to choose from & many are slightly tailored to better meet specific types of relationships (such as work, parent/child, spouse, you name it). I have personally found that it is worthwhile to learn about the general ideas first and then go on to also learn more about the dynamics of specific relationships that you find most likely to be troubling in your life.
Overall I have good relationships in life. I have had a long happy marriage so far & anticipate it will remain so. It was not always so peaceful as it is now, but we have both been willing to work on establishing better boundaries, respecting one another's boundaries and on communication. Now had I been the only one trying, this would be much harder to be effective. It is always worthwhile to do the work, even if the other person never does not, but I cannot say my happy marriage is my personal effort. It is because we both desire to have a loving, respectful relationship that allows each person to be as happy as they can be, while respecting the limits of each other.
The reason I say all that is to make sure I mention the limits of such personal work. I cannot work on myself enough to make other people healthier. If I devoted 24 hours a day to study bettering all my relationships, there would never be a time that it would be enough to solve them all because I am not the cause of all my relationship difficulties. I can only solve the pieces that are me. I can also learn to stop taking all things so personally because most things aren't as personal as they seem.
As an example, my sister & I are very different. She will say things like, "I don't know how you can stand having this old carpet". This is rude of course. It is overstepping too. It is like I first said, people closest to you often feel free to say things to someone they love that they would never dare say to a stranger. But here is the thing. She has to have a relatively fancy home to feel happy with it and with her life. I do not. I have a modest home because what makes me feel happy with it and with my life is financial security. As such, I focused on paying it off, versus fixing it up and I would love new carpet eventually, but it's not on my list yet for projects. I hate debt. I will not make payments if I do not actually need something, because I prefer that. What makes me feel best is saving money & buying what I want in cash. She would rather be in debt/make payments & have beautiful things now. That is fine. I am absolutely sure she will get it all paid, she is very competent and responsible. It's just not the way I want to do it. I respect her boundaries and what is not my business. As such, I would never say to her, "I do not know how you can stand owing money every month, so that your carpet isn't even paid off before you have it half worn out". I wouldn't say that because, it wouldn't even occur to me, and because I don't need or want her to live like me in order to feel okay with my life. If she is happy, then I am happy for her. She manages her own life quite well and it is her choice how to do that. If I did comment about how she chooses, then that is more about me than her. Perhaps it would mean that deep down I wish I felt comfortable to take on credit debt because I do hate that nasty carpet, or perhaps it would be a need I had to act as though my way is superior for all people. She has said she is jealous of my "financial freedom". I have worked very hard to be debt free. I always tell her, it has it's own price & some of that is old carpet and that she is highly capable, so she can't really want it or she would have it. I believe this completely. She can reach any goal she sets for herself. So I know what she says about my carpet isn't actually personal. It's not. I think it's her reminding herself why she has the bills she does & that she is actually okay with that because she likes what it provides in her life. I tease her when she says she is jealous of the "zero debt" that she can come visit my carpet to remind herself why she doesn't really want to be debt free.
And the last point I will make is that if I chose to be offended when she says something about my carpet, then it's my choice to do so. I don't actually have to, so I don't. She has a tremendous number of amazing qualities aside from all of this & I focus on those. I am sure too there are things about me she is gracefully choosing not to take issue with.
Part of getting along with people is also knowing you have flaws, and some people will see even flaws in you that you don't see in yourself. That isn't because you can't see those characteristics, but you personally see them as positive. My mother finds me far too bold & outspoken. She sees those as flaws. I just happen to disagree with her, but I am aware that those aspects can make her uncomfortable, so I try to respect that as well.
She would prefer to eat the wrong food at a restaurant that has a mistake, than to "bother" the wait staff. I would easily tell them there is an error (of course politely) and have it fixed. If I am with her & I see an error was made in her meal, I do not overstep & wave someone down to fix it. That would make her uneasy & she would prefer to just eat it. I respect a healthy boundary by not taking over her food. I set my own healthy boundary by not being infringed on by her preferences so if I were to get the wrong food by mistake, then I feel free to get it corrected.
And sorry for the novel. It's a deep question that requires a deeper answer if you want to actually get everything covered.