I went NC with a very close female relative for 5 years. Absolutely without doubt the right reason. We re-established a shallow relationship after that time because she had enough of love left in her to still care, and she managed to rein in her (medically assessed) severe personality disorders enough to be endurable for an hour or two. I would not and did not leave my child alone with her for a second.
Have gone virtually NC with my father. I am very sad about it but I don't need his authoritarian and callous shit. I don't use those adjectives lightly. He's useless as a grandparent.
Have also gone NC with a sister until I receive an apology for 6 months of abusive emails (I did check with a neutral and very honest friend who I can trust to tell me when I am wrong that I wasn't misreading or overreacting to the many mails). She's not a child sort of person so it's not a problem for the children.
None of the people I've gone NC with were good for me and they would not have been good for the children so no, no regrets. Or at least, a hell of a lot of regret that it was necessary and that they aren't loving people. I'd give anything for loving parents and I'd rather like the sister to be a nice aunt. But with things being as they are, well, life is too short and your children are far too precious to be exposed to highly unpleasant people.
The kids will come across enough bastards who go through life hurting others when they are grown, they don't need them at close quarters when they are young and vulnerable.