As you know well, in so many cultures (especially eastern ones,) having a child from a boyfriend or a girlfriend and generally from someone who is not married to you, is denounced and disapproved by many people.
Also, as you know, almost in every culture people call such a person with some specific qualities and use vulgar language about them! (At least that's the way is was in the past.) (Regardless of whether this is good or just a wrongdoing.)
I would call such behaviors "contrary to the social convention" in a specific society (, while usually in that society everyone is well aware about the routines and customs of a particular matter like having a child from someone.)
A usual or accepted way of behaving, especially in social situations, often following an old way of thinking or a custom in one particular society.
Now, I was wondering if the sentence below can be indicative of this matter in natural English. If no, then I wonder how shall I imply this message.
Having a child from friend (who you are not married to) is contrary to the social convention.