Problem here is that most of the time the woman gets custody of the child. In a lot of jurisdictions, even if you're taking care of the child 60% of the time, you might still have to pay child support based on your salary.
The moment you have kids with a woman, you're fvcked. And that's whether or not you're married, and whether or not you live together. You're paying child support based on your salary. If you have the child the vast majority of the time, you're still paying for them in terms of daily maintenance. Not only this, but you're also ordered to pay extraordinary expenses such as day care, dental/medical, and other normal expenses such as skiing or hockey or ballet lessons which can cost even more than child support. All these expenses have a way of digging into your wallet. And this does not include the tens of thousands of dollars you have to spend on a good lawyer.
Think this is unfair? Welcome to the Family Court Justice System
Not only this, but the girlfriend you live with, in certain jurisdictions she may also successfully claim much of your wealth. For example, in some places the gf can claim she is a common law spouse and that the home that you paid for and that is in only your name is basically a marital residence that she only equal rights to. Or, she can use a constructive trust argument to claim that any increase in the value of the home (sometimes it can double or more) should go to her because she helped with renovations and costs.