
468 Pa. 134 (1976)
360 A.2d 587
COMMONWEALTH of Pennsylvania ex rel. Fred H. MYERS
v.
Pandora L. MYERS, Appellant.
Supreme Court of Pennsylvania.
Submitted April 2, 1976.
Decided July 6, 1976.
*135 McCrea & McCrea, John McCrea, III, Newville, for appellant.
Sylvia H. Rambo, Carlisle, for appellee.
Before JONES, C.J., and EAGEN, O'BRIEN, ROBERTS, POMEROY, NIX and MANDERINO, JJ.


*136 OPINION OF THE COURT
ROBERTS, Justice.
This is an appeal from an order of the Court of Common Pleas of Cumberland County, entered April 5, 1974, transferring custody of two minor children from their mother to their father.[1] The Superior Court, in an opinion by President Judge Watkins, affirmed the order. Judge Hoffman filed a dissenting opinion and Judge Spaeth filed a concurring and dissenting opinion. The mother petitioned this Court for allowance of appeal, which we granted.[2] We reverse.
Appellee Fred Myers and appellant Pandora Myers were married on November 9, 1968, and became parents of two girls  Stacey, born March 8, 1969, and Kelli, born July 20, 1972. Fred is an enlisted man in the United States Air Force and was stationed in Korea from approximately March 1973 to January 1974. Pandora and the two children occupied a mobile home near Shippensburg during her husband's absence. On January 14, 1974, Fred returned home and learned that Pandora had become romantically involved with one Thompson. Fred separated from Pandora shortly after his return and moved in to his parents' home. He has since been transferred to Mississippi, where he now resides. Pandora and the two children left the mobile home on February 11, 1974, and moved into an apartment with Thompson. Thompson moved out of the apartment shortly before the custody hearing on the advice of Pandora's counsel.
*137 At the hearing, Pandora testified that she had filed for a divorce from Fred the morning of the hearing and stated that she and Thompson planned to marry once the divorce became final. She also stated that although she loved Thompson, she would cease all contact with him if that were necessary to retain custody of her children.
The hearing court awarded custody of Kelli and Stacey to Fred despite the fact that its order would result in the two children being moved from Pennsylvania. The court justified its action solely on Pandora's "blatantly immoral past conduct":
"Although mere moral lapses are not sufficient to deprive a mother of her child, where the immoral conduct is flagrant and persistent as here, it may not be disregarded in considering the child's welfare.. . . Our appellate courts recognize that a mother's immoral conduct would have a profound adverse effect on the morals of an impressionable young daughter, and such conduct would thus be pertinent to considerations of the best interests of the child.. . .
". . . Although the issue in child custody cases is the present fitness of the prospective custodian, Judge Woodside astutely noted . . . that `. . . as the present is merely the dividing line between the past and the future, the courts can best determine the appellant's probable future conduct by examining her past conduct.' To ignore the present respondent's blatantly immoral past conduct and award her custody of the children under these circumstances would set a highly undesirable precedent.. . ."
Although the hearing court, as fact-finder, must determine the weight to be given the testimony and the credibility of the witnesses, its findings must be supported by competent evidence. Commonwealth ex rel. Pruss v. *138 Pruss, 236 Pa.Super. 247, 344 A.2d 509 (1975); Davidyan v. Davidyan, 230 Pa.Super. 599, 327 A.2d 145 (1974). Moreover, the sole issue to be decided in custody proceedings between contending parents is the best interests and welfare of the child. Act of June 26, 1895, P.L. 316, § 2, 48 P.S. § 92 (1965); Commonwealth ex rel. Holschuh v. Holland-Moritz, 448 Pa. 437, 292 A.2d 380 (1972) (plurality opinion of Eagen, J., dissenting opinion of Roberts, J.); Gunter v. Gunter, 240 Pa.Super. 382, 361 A.2d 307 (1976); Commonwealth ex rel. Pruss v. Pruss, supra. We must therefore determine whether the hearing court's finding that the children's best interests would be served by granting custody to Fred is supported by competent evidence.
It is now beyond dispute that the mere fact of a parent's nonmarital relationship is insufficient to deny him or her custody of the children. Commonwealth ex rel. Holschuh v. Holland-Moritz, supra; Snellgrose Adoption Case, 432 Pa. 158, 247 A.2d 596 (1968); Gunter v. Gunter, supra.[3] Nevertheless, a parent's nonmarital relationships must be given close scrutiny in determining custody matters. The prevailing issue must remain the best interests of the child, and a nonmarital relationship is merely one of the circumstances which the court must consider before reaching its decision. Gunter v. Gunter, supra; Commonwealth ex rel. Staunton v. Austin, 209 Pa.Super. 187, 223 A.2d 892 (1966). As Professors Foster and Freed state in their review of Family Law:
"[U]nless it can be shown that [the mother's] affair had a direct impact upon the children, or that she had neglected them, her indiscretions are at most factors to be considered."
*139 Foster & Freed, Family Law, 1970/71 Annual Survey of American Law, N.Y.U. School of Law, 451, 463.
Two recent Superior Court cases illustrate the analysis to be employed when one parent has been involved in a nonmarital relationship. In Commonwealth ex rel. Likovich v. Likovich, 220 Pa.Super. 202, 287 A.2d 156 (1971), the record disclosed the following misconduct by the mother:
"[The mother, while married] maintained a home at various places in Westmoreland and Washington Counties, where she regularly entertained numerous male visitors; she permitted an unmarried couple to stay there; she slept with certain of her male visitors; she left the children with teenage baby sitters while she visited bars and taverns, where she consumed intoxicants, returning home as late as four a.m.; she encouraged drinking in her various homes; she permitted minors to drink there; she became pregnant and delivered a child in June, 1970, which she abandoned in the hospital for 49 days; and finally she left it with tavern owner Carl `Red' Barron, for adoption, refusing to name the father of the child; she became pregnant again in October, 1970, and was in that condition at the time of her divorce, which was procured by her husband in December 1970, and at the time of the hearing in this proceeding; she has named a minor, Ralph Lincavage, as the father of this child and promises to marry him as soon as he reaches the age of 21. . .."
Id. at 24, 287 A.2d at 157. The Superior Court found that the mother's home "reflects an atmosphere of uncleanliness and sexual promiscuity" and that her "immaturity is existent, unrelenting and reckless." The court, focusing on the effects of the mother's conduct on the children, concluded:
"[T]he environment reflected by the above summarization and in which these children have been maintained is not conducive to their welfare."
*140 In Gunter v. Gunter, supra, the mother, after the father left the family, entered into a nonmarital relationship with one Clawson. There was no evidence of sexual promiscuity, and the relationship was shown to be "steady" and "familial." Clawson supported the child and displayed love and affection toward him. The hearing court ordered that the child's custody be changed from the mother to the father. The Superior Court, in vacating the order, stated:
"Considered by itself, there is nothing [in the record] to suggest that the relationship between the mother and Clawson, albeit non-marital, is detrimental to [the child's] best interests; or, to state the issue more accurately, there is nothing to suggest that [the child's] best interests will be served by taking him away from his mother, with whom he has been since his birth, and giving him to his father. Nor does the balance of the record support such a suggestion."
Id. at 396, 361 A.2d at 315.[4]
*141 As these cases illustrate, it is the effect of the nonmarital relationship on the child and not the fact of the relationship itself which is crucial to a custody decision. If the evidence shows that a parent's conduct has had harmful effects on the child the court may be justified in denying custody to that parent. On the other hand, if the evidence shows that the parent's conduct has not adversely affected the child and that the parent has taken good care of the child, then the best interests of the child may dictate that the parent retain custody. In each case, all relevant circumstances must be examined to determine what action would be in the best interests of the child.
We must therefore determine whether, in the case before us, Pandora's nonmarital relationship with Thompson so adversely affected her children that it would be in their best interests to remove them from their mother. There is no evidence in this record to support such a conclusion.
Every witness at the hearing stated that Pandora is a good and loving mother who has at all times provided good care for the children's physical and emotional needs. Pandora has cared for each child since birth and has maintained a close emotional relationship with them. Fred testified that Pandora is a loving and caring mother:
"Q. [by appellee's counsel] Now, Mr. Myers, as far as the general care and upkeep of these children, is it your opinion that your wife does take adequate care of their physical needs . . .?
"A. Yes, she does.

*142 "Q. [by appellant's counsel] With the exception of what you have related, Mr. Myers, about your wife's involvement with Mr. Thompson and her residence with him, with the exception of those facts do you believe your wife to be a good mother to the two children?
"A. Correct.
"Q. And does she care adequately and in fact quite well for their physical and emotional needs?
"A. Correct.
"Q. Are they quite attached, that is are the children quite attached to their mother?
"A. Kelli, yes, Stacey I think is closer to me than her mother."[5]
The record shows that Fred's only objection to Pandora's care and custody of the children concerned race. Pandora, Fred and the children are white; Thompson is black. Fred testified that he instituted the custody action only because he objected to his children being raised by an interracial couple, not because he believed Pandora to be an unfit mother.[6]
*143 In Commonwealth ex rel. Lucas v. Kreischner, 450 Pa. 352, 299 A.2d 243 (1973), custody of the children was denied a mother and granted to the natural father (her first husband) because of the possible detriments to the children stemming from the mother's interracial remarriage. This Court reversed the hearing court's order and stated unequivocally that problems related to racial identity were inapplicable in custody proceedings:
"`[I]n a multiracial society such as ours racial prejudice and tension are inevitable. If . . . children are raised in a happy and stable home, they will be able to cope with prejudice and hopefully learn that people are unique individuals who should be judged as such.'"
Id. at 356, 299 A.2d at 246 (quoting dissenting opinion of Judge Hoffman, 221 Pa.Super. 196, 207, 289 A.2d 202, 207 (1972)).
*144 Thus, Fred's primary concern in instituting his custody action, the racial problems he contends his children might have, is not relevant in denying Pandora custody.[7] He produced no other evidence which would indicate that Pandora's relationship with Thompson, or any other behavior on her part, adversely affected the children. The evidence shows that Pandora and Thompson have a serious rather than a "trifling" relationship which she expects will lead to marriage. Moreover, there was no evidence that Pandora was sexually promiscuous. Pandora testified that she had been careful to refrain from any conduct in the children's presence which might in any way adversely effect them, that her nonmarital relationship had no prejudicial or detrimental effect on the children, and that she would be willing, if necessary, to refrain from any contact with Thompson until she could marry him. It cannot be concluded on this record that the mother's behavior had a detrimental effect on the children.
Moreover, the record indicates that granting custody to Fred would have adverse consequences for the children. He is a sergeant in the Air Force and has already had long absences from the children. Because he is now in Mississippi and subject to other transfer, he would be required to remove them from their home to travel hundreds of miles to a new residence. Such action would effectively deny the children any contact with their mother, who has cared for them their entire lives and to whom they have a strong emotional attachment. In these circumstances, the uncontradicted evidence that Pandora is a loving and caring mother requires that the hearing court's order be reversed and that the custody of the children be awarded to the mother.
*145 Order of the Court of Common Pleas for Cumberland County reversed and custody of Stacey and Kelli Myers awarded to mother-appellant.
NOTES
[1]  The hearing court awarded temporary custody to the father's parents on April 5, 1974, in order to keep the children in Pennsylvania pending appeal. The children have remained with their grandparents since that time. The children were one and one half and five years old at the time of the hearing. They are now three and one half and seven years old.
[2]  This appeal is brought pursuant to the Appellate Court Jurisdiction Act, Act of July 31, 1970, P.L. 673, art. II, § 204(a), 17 P.S. § 211.204(a) (Supp. 1975).
[3]  Indeed, such a rule could lead to absurd results. If both parents were shown to have had nonmarital affairs, both parents could be denied custody even if such a result would be clearly detrimental to the child's welfare. Gunter v. Gunter, 240 Pa.Super. 382, 361 A.2d 307 (1976).
[4]  See Commonwealth ex rel. Staunton v. Austin, 209 Pa.Super. 187, 223 A.2d 892 (1966), and Commonwealth ex rel. Gervasio v. Gervasio, 188 Pa.Super. 95, 145 A.2d 732 (1958). In Austin, the mother, after separating from her husband, lived with one Staunton for thirteen years and had five children with him. She granted temporary custody of one child to friends due to emotional problems she was having. Two years later she attempted to regain custody. The Superior Court held that her nonmarital relationship with Staunton was not a bar to regaining custody because it had proven to be "durable" and a cohesive force for the children. In Gervasio, the mother had entered an adulterous relationship with one Karabell, whom she later married. The court found that the home was clean and that the children were well cared for. Custody was awarded to the mother rather than the natural father despite the nonmarital affair.

See also Commonwealth ex rel. Holschuh v. Holland-Moritz, 448 Pa. 437, 292 A.2d 380 (1972) (plurality opinion of Eagen, J., joined by O'Brien, J. and Pomeroy, J.) (case remanded for hearing in which the mother would be granted custody despite past immoral conduct provided "the home environment has been corrected in good faith"); Commonwealth ex rel. Sorace v. Sorace, 236 Pa.Super. 42, 344 A.2d 553 (1975) (father's visitation rights in his home allowed although the father is living in an extramarital relationship. The relationship was "not a trifling one" and the parties planned to marry once the father obtained a divorce; the lower court was impressed with the paramour's "demeanor, level-headedness and maternal ability"; the father was found to be a competent parent; and the home was morally satisfactory in all other respects.)
[5]  Fred's mother and Pandora's babysitter also testified that Pandora was a loving and caring mother. There is no evidence to the contrary.
[6]  Fred gave the following testimony on cross-examination:

"Q. [by appellant's counsel] You've alleged that you believe continued presence of those two children with their mother and her paramour is detrimental and prejudicial to their best interest. May I ask you to be a little more specific about what the detriment and what the prejudice to their interest is that you see or believe?
"A. Well, from the time I was home until the time I left to go back, the whole time my children were very seldom around white people at all. The only time I even seen them they was all around black people and they have no confirmation of what white is, really, I don't think.
"Q. You are aware that they have a babysitter, Mrs. Scott, who is black and who is here today?
"A. Correct.
"Q. And do you have any reason to believe that she is not a capable and competent babysitter for them during the day when your wife works?
"A. I couldn't tell you. I don't know the woman.
...........
"Q. Now, you say that they're around black people, you must mean around more than one black person?
"A. Correct.
"Q. And you say or believe that they have a problem with their own racial identity because of this?
"A. To a sense, yes, especially for the youngest one.
..........
"Q. And how does the young one especially suffer by being around persons of a different race than hers?
"A. Well I can't really say how she would suffer but I mean it is hard when you come home and your own daughter don't know you, won't let you hold her or anything like that."
Fred's counsel, when cross-examining Pandora, again stressed the racial problems Kelli and Stacey would have if Pandora were to marry Thompson. This questioning covers four pages of transcript, nearly one-half of the cross-examination, and includes detailed inquiries into the potentially "severe, emotional, [and] psychological problems" for the children at school and in the community. There was no other evidence in the cross-examination concerning detriments to the children.
[7]  The hearing court stated in its opinion that racial factors did not influence its decision. However, it relied solely on the existence of the nonmarital relationship to deny Pandora custody despite the lack of any evidence that the relationship adversely affected the children.
