Mass. Gen. Laws ch. 209C, § 10
(a) Upon or after an adjudication or voluntary acknowledgment of parentage, the court may award custody of a nonmarital child to either parent or to them jointly or to another suitable person as hereafter further specified as may be appropriate in the best interests of the child.
In awarding custody to one of the parents, the court shall, to the extent possible, preserve the relationship between the child and the primary caretaker parent. The court shall also consider where and with whom the child has resided within the six months immediately preceding proceedings pursuant to this chapter and whether one or both of the parents has established a personal and parental relationship with the child or has exercised parental responsibility in the best interests of the child.
In awarding the parents joint custody, the court shall do so only if the parents have entered into an agreement pursuant to section eleven or the court finds that the parents have successfully exercised joint responsibility for the child prior to the commencement of proceedings pursuant to this chapter and have the ability to communicate and plan with each other concerning the child's best interests.
(e) In issuing any temporary or permanent custody order, the probate and family court shall consider evidence of past or present abuse toward a parent or child as a factor contrary to the best interest of the child. For the purposes of this section, ''abuse'' shall mean the occurrence of one or more of the following acts between a parent and the other parent or between a parent and child:
(a) attempting to cause or causing bodily injury; or (b) placing another in reasonable fear of imminent bodily injury. ''Serious incident of abuse'' shall mean the occurrence of one or more of the following acts between a parent and the other parent or between a parent and child:
(b) placing another in reasonable fear of imminent serious bodily injury; or (c) causing another to engage involuntarily in sexual relations by force, threat or duress. For purposes of this section, ''bodily injury'' and ''serious bodily injury'' shall have the same meanings as provided in section 13K of chapter 265. For the purposes of this section, if the child was conceived during the commission of a rape and the parent was convicted of said rape, under sections 22 to 23B, inclusive, of chapter 265 or section 2, 3, 4 or 17 of chapter 272, said conviction shall be conclusive evidence of a serious incident of abuse by the convicted parent.
(i) imposing any other condition that is deemed necessary to provide for the safety and well-being of the child and the safety of the abused parent.
Nothing in this section shall be construed to affect the right of the parties to a hearing under the rules of domestic relations procedure or to affect the discretion of the probate and family court in the conduct of such hearing.
A probate and family court's finding by a preponderance of the evidence, that a pattern or serious incident of abuse has occurred shall create a rebuttable presumption that it is not in the best interests of the child to be placed in sole custody, shared legal custody, or shared physical custody with the abusive parent. Such presumption may be rebutted by a preponderance of the evidence that such custody award is in the best interests of the child. For the purposes of this section, an ''abusive parent'' shall mean a parent who has committed a pattern of abuse or a serious incident of abuse.
For the purposes of this section, the issuance of an order or orders under chapter 209A shall not in and of itself constitute a pattern or serious incident of abuse; nor shall an order or orders entered ex parte under said chapter 209A be admissible to show whether a pattern or serious incident of abuse has in fact occurred; provided, however, that an order or orders entered ex parte under said chapter 209A may be admissible for other purposes as the court may determine, other than showing whether a pattern or serious incident of abuse has in fact occurred; provided further, that the underlying facts upon which an order or orders under said chapter 209A was based may also form the basis for a finding by the probate and family court that a pattern or serious incident of abuse has occurred.
If the court finds that a pattern or serious incident of abuse has occurred and issues a temporary or permanent custody order, the court shall within 90 days enter written findings of fact as to the effects of the abuse on the child, which findings demonstrate that such order is in the furtherance of the child's best interests and provides for the safety and well-being of the child.
If ordering visitation to the abusive parent the court shall provide for the safety and well-being of the child, and the safety of the abused parent. The court may consider: