The source in Halacha regarding tznius/hair covering in private areas begins From the passage in Ketubot (72b),
It would seem that a woman is only required to cover her head when she is out on the street. In her house or courtyard, she may walk about with her head uncovered. Although some have attempted to explain the gemara differently (Bach, Even Ha-Ezer 115), this is the plain understanding of the gemara and the Rishonim.
There is, however, a Talmudic source that seems to praise a woman who is meticulous about covering her hair even in the privacy of her own home:
Furthermore, it is told of R. Yishmael ben Kimchit [who was a High Priest] that he went out and talked with a certain [non-Jewish] lord in the street, and spittle from his mouth squirted on his garments [rendering him impure], whereupon Yosef his brother entered and ministered in his stead, so that their mother saw two High Priests on one day. The Sages said to her: What have you done to merit such [glory]? She said: Throughout the days of my life, the beams of my house have not seen the plaits of my hair. They said to her: There were many who did likewise and yet did not succeed. (Yoma 47a)
The closing words of the Sages imply that they questioned the explanation provided by Kimchit. Nevertheless, there are those who inferred from here that it is good for a woman to be meticulous about covering her hair even at home, and even when not in the presence of other men. To this we can add the words of the Zohar, which is very stringent about a woman covering her hair. Just as many learned from the Zohar to be stringent about covering the entire head, they learned from it to be stringent about covering the head even at home and in one's courtyard.
It should be noted that the accepted practice for generations has been to be stringent about this. So ruled the Chatam Sofer: "The rule that emerges: All hair anywhere on the head or forehead of a married woman, even in her room, is a sexual incitement" (Responsa Chatam Sofer I:36).
Although it would appear that in the time of the gemara, women were not meticulous about covering their heads in their courtyards, but only on the street, women have been stringent about this for many generations, until our very day. The reason seems to be that since a woman is meticulous about covering her hair outside, removing that cover in her house in the presence of strangers is deemed an overly intimate gesture. Of course, in the absence of strangers, the great majority of Jewish women do not conduct themselves as did Kimchit, and do not cover their heads in the privacy of their own homes.
It should further be noted that the propriety of a wig is subject to major controversy. The mishna in Shabbat 64b speaks explicitly of a woman who goes out into the public domain wearing a wig. The Shiltei Gibborim (no. 375) demonstrates that the gemara refers to a married woman who uses the wig to cover her head, and he writes that an allowance should be granted even to a wig made from the hair of that very woman. The Peri Megadim (Orach Chayyim 75, Eshel Avraham no. 5) and the Iggerot Moshe (Even Ha-Ezer II:12) rule similarly.