Of course intent matters. There’s a massive difference between being intentionally insulting and accidentally offending someone. But…
Even with the best of intentions, it’s possible to be loved and not feel loved. To be supported and not feel supported. So while positive intent (or ignorance) should get us off the hook, if we care, we learn to communicate our intent better. In ways that others hear us.