According to the provisions of the Marriage Law, children born in marriage or out of wedlock are equal. It cannot be said that if men and women are not married, children born out of wedlock are not children of their parents. The blood relationship between children born out of wedlock and their parents cannot be denied and divided by anyone.
Therefore, the legal status of children born in cohabitation is the same as that of children born in wedlock. Children born in cohabitation enjoy the right to be raised by their parents, the right to inherit and all other rights enjoyed by legitimate children.
The two parties can negotiate to decide who should own the children born without marriage. Since the issue of who should own the custody of children born in cohabitation is actually a civil issue, the two parties can of course reach an agreement on who should own the custody of children born in cohabitation.
That is to say, the question of who is entitled to the custody of the children born in the same household is generally determined by the parents through consultation. If it is difficult for both parties to reach an agreement on the ownership of the custody of the children born in the same household, they can file a lawsuit and the court will decide.
Article 36 of the Marriage Law states that the relationship between parents and children shall not be eliminated by the divorce of parents.