delivered the opinion of the court.
This is a proceeding by habeas corpus, on the part of the father to obtain control and the custody of his infant child. The respondents are the maternal aunt of the infant child and her husband. The facts are, briefly, that the father, an Ohio ' man, married in Frederick county, Virginia, the mother of this infant, some years ago, who bore him three children, the third being this infant, who was born on the 13th of December, 1872, and the mother died three weeks after; whereupon the infant was taken charge of by the mother’s sister, and brought to Virginia with the consent of the father, where she, the said infant, has remained ever since. In the meantime, the father has married another wife, who is childless. The two other children, a girl and a boy, have always remained with the father; and during the thirteen years of his daughter’s life in Virginia, he has only seen her two or three times, and has never seen her at all except when called to Virginia on business connected with her mother’s property. And he has contributed nothing to her support except the nominal rent obtained from the grandmother for the undivided interest of the first wife in the home place. The grandmother, who had long been greatly enfeebled by age and bodily infirmity, having died, the father came to Frederick county, Virginia, and announced his purpose of carrying his daughter, Bessie» the subject of this controversy, with him out to Ohio, having in the meantime sold her mother’s land, and qualified as her guardian.
Finding his daughter.in delicate health, and greatly opposed to going with him, and her aunts anxious to keep her, he entered into an agreement with the respondents that if they would support the child without charge against him as her guardian they could keep her; to which they assented. And *435shortly after, the said father sent them the following paper to sign, without the words in italics:
“Winchester, Va., April 28th, 1885.
“ Whereas Hugh M. Merritt, guardian of his minor child, Sarah E. V. Merritt, has left said child in our care and keeping (until she is tiventy-one years of age), we, the undersigned, Jacob L. Swimley and Mary 13. Swimley, do agree and promise to bear all expenses of her boarding, clothing, and tuition, <&c., without making charge against said Hugh M. Merritt as guardian of said child.”.
The respondents inserted the words until she is twenty-one years of age, which they insist was the agreement, signed it “J. L. Swimley, Mary D. Swimley,” and delivered it to the counsel of the father. When this paper was received by Hugh M. Merritt he refused to sign it, admitting that he had made the agreement without the added words, but denying that the arrangement was to continue until the .child was twenty-one years of age, and forthwith instituted these proceedings in the county court of Frederick. A mass of evidence was taken on both sides, when the judge of the county court remanded the infant to the custody of the defendants, and dismissed the petition and writ. Whereupon the plaintiff applied for a writ of error to the circuit court of Frederick county which was refused. Whereupon the said plaintiff applied for a writ of error to this court, which was awarded.
All the evidence is certified, and by agreement of parties entered of record, the case is submitted to this court without any burden upon the exceptor; it being agreed that all the evidence on both sides is to be considered' as in a chancery case on appeal. It is proved in the case that the plaintiff in error is the father and guardian of the infant child. And it *436is conceded that the legal right is with him, as a general proposition, if he is a fit and suitable person; unless there are circumstances which take the case out of the general rule, the father is entitled to the custody and control of his infant child.
It was said bj7 a learned judge (State v. Smith, 6 Greenl., 462), “that the father is generally entitled to the custody of his infant children is a principal resulting from his obligation to maintain, protect and educate them. These are duties thrown upon him by the law of nature as well as of society, which he is not permitted to disregard, and which he could not conveniently discharge if the object of those duties was withdrawn from his control. The right, however, is neither unlimited nor inalienable. It continues no longer than it is properly exercised. And whenever abused, or whenever the parent has become unfit, by immoral or profligate habits, to have the management and instruction of children, courts of appropriate jurisdiction have not hesitated to interfere to restrain'the abuse, or to remove the subject of it from the custody of the offending parent.”
As a general rule the writ of habeas corpus, and all actions on it, are governed by the judicial discretion of the court, in directing which all the circumstances are to be taken into consideration. In the case of a child of tender years, the good of the child is to be regarded as the prominent consideration. There may be cases in which the court would not interfere in favor of the father to take the child from any safe custody to deliver it to him, as when he is a vagabond, &c. Com’th v. Briggs, 16 Pick. 203. But there may be cases where the reputation of the father is stainless; he may not be afflicted with the slightest mental, moral or physical disqualification from superintending the general welfare of the infant; the mother may have separated from him without the shadow of a pretense of justification; and yet the interests of the child may *437imperatively demand the denial of the father’s right, and its continuance with its mother. Com’th v. Addricks, 5 Binn. 520; D’Hauteville Case, decided by the court of general sessions of Philadelphia in 1840. The court, upon a proceeding of habeas corpus, is .not bound to deliver the child to the father, but may act upon its discretion, according to the circumstances of the particular case, the principle being well established that a court is not bound by a fixed principle of right to restore a child to its father, but may at its discretion withhold it. The question occurs, under what circumstances may that discretion be exercised? It is to be observed that' in all cases the interest and welfare of the child is the great leading object to be obtained, and therefore, if it be of an age sufficiently matured to judge for itself, the court will free itself from the responsibility of determining the controversy by leaving it at liberty to go where it pleases. Rex v. Smith, 2 Story, 982; 8 John. 328.
The decided cases establish the principle that the court has a discretion upon the subject, and that the interest of the child is the chief consideration to be looked to. In the case of Fisher v. Alston, 6 How. 406, Mr. Justice Turner said, after reviewing the case where a guardian sought the possession of the children against the mother, “in cases like the present proceeding under the writ of habeas corpus, the technical legal rights of the parties do not govern,” and the children were given to the mother. In a case like this, the welfare of the infant is the pole-star by which the discretion of the court is to be guided. But the legal rights of the parent or guardian are to be respected. They are founded in nature and wisdom, and are essential to the peace, order, virtue, and happiness of society. But they may have been abandoned, or released, or transferred, says a learned author. Hurd on H. C., page 528. “ It frequently happens that the father of an infant, upon the death of its mother, or other event, makes an arrangement by *438which he gives his child to a third person, or relinquishes his custody of it until it is of age, upon consideration that the party agrees to adopt the child and care for it as his own; and then, after the affections of both child and adopted parent become engaged, and a state of things has arisen that cannot be altered without risking the happiness of his child, will attempt to reclaim the custody of the child. In such a case hut few rules are found for the government of the court; and there are decisions, both in England and this country, to the effect that the father would not be bound by such a transaction, and would recover the custody of the child, even though the interests of the child had been promoted by the original transfer. But the better opinion is that the father, in such a case, is not in a position to require the interference of the court in favor of a controlling legal right, on his part, against the rights, such as they are, the feelings and the interests of other parties. See Pool v. Golt, 14 Law Rep. 269; The State v. Smith, supra; McDower’s Case, 8 Johnson R., supra. The parent may emancipate his child by voluntarily relinquishing his claim to the services of the child, or by permitting the child to contract marriage, &c., and he may transfer to another his right of custody, which he may thus abandon or forfeit, when the interests of the child are not injured by the assignment. And the court could not declare that custody which is held under fair agreement with the father, and is not injurious to the child, to be an illegal restraint.”
In this case the father transferred the custody of his child, before it was a month old, to female relatives, who have tenderly nursed and reared it, almost altogether without aid from the father. Whether from necessity or choice, the father has permitted this child to grow up a stranger to him, almost unknown to him by sight, perhaps entirely so. In the new home the tenderest ties of affection have been wound around *439her. She appears in the light of this evidence as a lonely young girl, fourteen years old next December, so intelligent and cultivated and matured beyond what is usual for her age as to be almost a woman; she has impressed the learned judge of the county court with her maturity of judgment, and she clings fondly to her adopted home, and declares that it would almost kill her to be torn from her happy surroundings and transplanted in that unlovely Ohio home among strangers. Let us contemplate for a moment this Western home, into which this father would compel the entrance of his daughter against her will. Her own mother has been long ago laid beneath the sod and forgotten. Another wife is there, childless herself, and using her sixteen-year-old step-daughter and step-son, younger still, as domestic servants. If the evidence is to be credited, she is a female of strong passions, and is fierce of temper, and a terror to this young girl, and bore the worst reputation before her marriage a few years ago. This home, as compared with the present surroundings of this young girl, is full of hardships and discomfort, and one to which she was not invited until she had grown to sufficient size to be useful, and her father suggests that she should be taught manual labor, a species of education up to this time neglected, he thinks, so that she could not make her living in that way. The attempts to discredit the child’s present surroundings are wholly abortive. Her aunt is a reputable married woman, and her husband a man of stainless name and life. They have no children of their own, and are tenderly attached to their adopted child.
Can it be held to be to the interest of this child to tear her rudely against her own wishes from this happy home, to place her in the ruder surroundings in the far West? Upon what principle, not in itself cruel and revolting, could it be so held? The real question in a case like this is not what are the rights *440of the father or the other relative to the custody of the child, or whether the right of the one be superior to that of the other, hut what are the rights of the child ? This cannot be considered as a question involving a right of property in the child. The true view is that the rights of the child are first to be considered and those rights are clearly to be protected in the enjoyment of its personal liberty, according to its own choice, if „ arrived at the age of discretion, and if not, to have its personal safety and interests guarded and secured by the law, acting through the agency of those who are called on to administer it.
The learned judge of the county court seems to have given great weight to the wishes and choice of the child, who appeared to him to be of sufficient age and judgment to exercise this discretion; and in that he has our entire concurrence.
The order remanding the child to the custody of the respondents was plainly right, and will be affirmed. It is not proper to pass upon any other question under these proceedings, and the order of the county court, appearing to be without error, the same is affirmed.
Judgment arrirmed.