This appeal is from a judgment rendered in a proceeding in the nature of habeas corpus which awarded custody of the parties’ minor child to the father who was the applicant in the proceeding.
The mother had been awarded custody of the child in July 1967 in a divorce proceeding and the father was given visitation privileges. In a subsequent proceeding in the nature of habeas corpus, a judgment was rendered on May 27, 1968, again awarding the child to the mother with visitation privileges to the father.
The evidence shows that the mother and child were living in Gainesville, Florida. On December 5, 1968, she remarried and moved to New York City to establish a new home. On December 25, 1968, she brought the child to visit with her father for a week in Laurens County, Georgia. While she was there, this proceeding in the nature of a habeas corpus was served on *197her alleging that a change in conditions had occurred since the former habeas corpus hearing and that the best interest and welfare of the child would be served by placing her in the custody of the father.
The mother testified that she and her five-year-old daughter lived in an apartment in New York with her present husband; that the child had a bedroom of her own; that she was well cared for; that her relationship with her stepfather was good and that there had been no disagreements among them. She further testified that her present husband had been married previously; that he was separated from his former wife for a long time before his divorce; that before he obtained a divorce from his former wife, he had asked her to marry him; that she had refused to discuss the matter until he had obtained a divorce; and that her present home was a fit and proper place for the daughter to live.
The father testified that he had had psychiatric treatment and shock treatments in the past; that he had been treated by a physician at least six times during the year for depression caused by the separation from his daughter; that he was examined by a psychiatrist on December 12, 1968; that he believes that if he had custody of his daughter, all of his problems would be solved; that he lives in an apartment containing one bedroom, a den, kitchen and bathroom and that he would put up a cot, obtain a maid, and a larger apartment if the child were awarded to him.
The order of the trial judge stated: “From the evidence it is apparent that the defendant and her present husband were infatuated with each other prior to his divorce on October 29, 1968, and even prior to the filing of his petition for divorce on September 21, 1968, and were in constant contact with each other subsequent to May 27, 1968. This is borne out by the fact that it is inconceivable that defendant’s present husband would have proposed marriage even before the filing of his divorce and the fact that the defendant did not reveal to plaintiff any plans for moving from Gainesville, Florida when, in fact, she had an opportunity to do so. Based on the foregoing along with the other evidence in said case custody of the minor child, Leigh Phillips, is awarded to the plaintiff as the court does not consider the home of Dr. Barata *198a fit and proper home to permanently rear said child.” Visitation privileges were given to the mother. Held:
Argued March 10, 1969 Decided March 20, 1969. Nelson & Nelson, Carl K. Nelson, Jr., for appellant. Beverly B. Hayes, for appellee.“ ‘In all writs of habeas corpus sued out on account of the detention of the child, the court on hearing all the facts may exercise its discretion in awarding the custody of the child. Such discretion, however, is not arbitrary or unlimited, but is a discretion guided and governed by the rules of law. The power ought to be exercised in favor of the party having the legal right, unless the circumstances of the case would justify the- court, acting for the welfare of the child, in refusing it.’ McDowell v. Gould, 166 Ga. 670 [144 SE 206]. See also Miller v. Wallace, 76 Ga. 479 (2 ASR 48); and Hill v. Rivers, 200 Ga. 354 (37 SE2d 386). The plaintiff in error in this case, because of the decree awarding him the custody of the children here involved, had the legal right to their custody. Hill v. Rivers, supra. Since it does not appear that there is any substantial reason why the plaintiff in error should be deprived of the custody of the children here involved, and since it has not been shown that there has been any substantial change in conditions since the original decree was rendered, the judgment of the court below was error.” Peeples v. Newman, 209 Ga. 53, 57 (70 SE2d 749). The mother in the instant case was awarded custody of the child twice within less than one year, the last order being just 7 months before the filing of this proceeding. The mother had the legal right to custody and we do not find any evidence of a change in conditions affecting the welfare of this child which would support the judgment of the court below in awarding her to the father.
Judgment reversed.
All the Justices concur.