3011. Best interest of child; considerations
(a) In making a determination of the best interests of the child in a proceeding described in Section 3021, the court shall, among any other factors it finds relevant and consistent with Section 3020, consider all of the following:
(1) The health, safety, and welfare of the child.
(2)(A) A history of abuse by one parent or any other person seeking custody against any of the following:
(i) A child to whom the parent or person seeking custody is related by blood or affinity or with whom the parent or person seeking custody has had a caretaking relationship, no matter how temporary.
(ii) The other parent.
(iii) A parent, current spouse, or cohabitant, of the parent or person seeking custody, or a person with whom the parent or person seeking custody has a dating or engagement relationship.
(B) As a prerequisite to considering allegations of abuse, the court may require independent corroboration, including, but not limited to, written reports by law enforcement agencies, child protective services or other social welfare agencies, courts, medical facilities, or other public agencies or private nonprofit organizations providing services to victims of sexual assault or domestic violence. As used in this paragraph, “abuse against a child” means “child abuse and neglect” as defined in Section 11165.6 of the Penal Code and abuse against any of the other persons described in clause (ii) or (iii) of subparagraph (A) means “abuse” as defined in Section 6203.
(3) The nature and amount of contact with both parents, except as provided in Section 3046.
(4) The habitual or continual illegal use of controlled substances, the habitual or continual abuse of alcohol, or the habitual or continual abuse of prescribed controlled substances by either parent. Before considering these allegations, the court may first require independent corroboration, including, but not limited to, written reports from law enforcement agencies, courts, probation departments, social welfare agencies, medical facilities, rehabilitation facilities, or other public agencies or nonprofit organizations providing drug and alcohol abuse services. As used in this paragraph, “controlled substances” has the same meaning as defined in the California Uniform Controlled Substances Act, (Division 10 (commencing with Section 11000) of the Health and Safety Code).
(5)(A) When allegations about a parent pursuant to paragraphs (2) or (4) have been brought to the attention of the court in the current proceeding, and the court makes an order for sole or joint custody to that parent, the court shall state its reasons in writing or on the record. In these circumstances, the court shall ensure that any order regarding custody or visitation is specific as to time, day, place, and manner of transfer of the child as set forth in subdivision (c) of Section 6323.
(B) This paragraph does not apply if the parties stipulate in writing or on the record regarding custody or visitation.
(b) Notwithstanding subdivision (a), the court shall not consider the sex, gender identity, gender expression, or sexual orientation of a parent, legal guardian, or relative in determining the best interests of the child.