thumb|300px|The Biblical story about [[Joseph (son of Jacob)|Joseph and Potiphar's wife is an example of the risks with yichud.]]

In Jewish religious law (halakha), the laws of yichud () prohibit seclusion in a private area of a man and a woman who are not married to each other. Such seclusion is prohibited out of fear that sexual intercourse or other, lesser acts may occur. A person who is present in order to prevent yichud is called a shomer.

The laws of yichud are typically followed in strict Orthodox Judaism. Adherents of Conservative and Reform Judaism do not generally abide by the laws of yichud.

The term "yichud" also refers to a ritual during an Ashkenazi Jewish wedding in which the newly married couple spends a period secluded in a room by themselves. In earlier historical periods, as early as the talmudic era, the couple would have sexual intercourse at this time, but that practice is no longer current.

Source of the prohibition

Deuteronomy 13:7 says: <blockquote>If your very own brother, or your son or daughter, or the wife you love, or your closest friend secretly entices you, saying, 'Let us go and worship other gods, gods that neither you nor your ancestors have known...'</blockquote>

The Talmud gives an explanation to the passage, which is supposed to be a hint of yichud:

<blockquote>Said Rabbi Johanan on the authority of Rabbi Ishmael, Where do we find an allusion to yihud in the Torah? - For it is written: If thy brother, the son of thy mother, entices thee [etc.]: does then only a mother's son entice, and not a father's son? But it is to tell you: a son may be alone with his mother, but not with any other woman interdicted in the Torah.</blockquote>

thumb|200px|According to Talmud, Amnon's rape of his half-sister Tamar led King David to extend the prohibition of yichud to unmarried girls. 17th-century painting.

The Talmud also claims that after the rape of Tamar, daughter of David, when she was left alone with her half-brother Amnon, David and his high court extended this prohibition to unmarried girls as well. Later, in the times of Shammai and Hillel the Elder, the prohibition was extended to include a non-Jewish woman. These rules are discussed in the Talmud.

Most rishonim define the prohibition of yichud as a Torah law. Although Maimonides writes that the prohibition of yichud is derived from divrei kabbalah (Bible texts later than the Pentateuch), many interpret his words as meaning that it is a Torah law, though some regard it as a rabbinic prohibition.

Rashi maintained that insofar as the prohibition of yichud is mandated by the Torah, it is an essential prohibition, whereas rabbinical extensions of the prohibition are enacted as a fence meant to distance a person from forbidden relationships. Hence, leniencies would apply only to the rabbinic additions to the laws of yichud. Halachic consensus, following Maimonides, is, though, that leniencies apply even to Torah-mandated yichud laws. Even seclusion of short duration is forbidden, if it could potentially last longer.

Leniencies

There are a number of circumstances under which the prohibition of yichud may be circumvented. Typically, these apply fully to yichud with an observant Jew. Meeting a non-Jew or a secular Jew may require more scrupulousness. This ruling has been interpreted and enlarged in various ways: 1. the door is actually open 2. when the door is closed but unlocked 3. then door is locked, but somebody with a key is liable to come in at any time 4. the door is locked, but there is a reasonable possibility that people may knock on the door and expect to be answered (according to Moshe Feinstein). A woman being secluded with another man is also justified when people outside can see through the window what is going on inside the house. In case of a close, long-standing friendship between the man and the woman, however, a more stringent behavior is expected.

According to Rashi, yichud is permitted when at least three women are present, but most poskim follow Maimonides, who ruled that no number of women present circumvents the prohibition of yichud. Many poskim permit yichud in the presence of the man's grandmother, mother, daughter, granddaughter or sister (over seven years), but do not accept the woman's daughter, granddaughter or sister. Yichud between a brother and a sister above the age of Bar and Bat Mitzvah is considered appropriate for a short term, but not when their parents are away for an extended period of time. There are various opinions about the duration of a permitted yichud. Some poskim allow only up to three nights; others allow up to thirty days. If the brother and sister live separately and one comes to visit the other, yichud is permitted as long as they do not stay longer than the normal stay of a house guest (where circumstances like the distance of their residence is taken into account). However, when a sibling moves in on a permanent basis, yichud is forbidden even for one day.

Unmarried couples

A man and woman who are engaged to be married may not dwell together unless other people are in the same house, and the door is unlocked. Leaving the door slightly ajar is commendable. They may not stay together even on a temporary basis, such as in a hotel. Regardless of whether yichud takes place or not, girlfriend/boyfriend relationships are forbidden according to some, since dating, according to halacha, should not serve other purposes than finding a suitable marriage partner.

Babysitting and caregiving

thumb|250px|Visiting a doctor's or dentist's office has to occur during regular office hours, when people may enter unexpectedly.

Unless it is one's own child, grandchild or sibling, a female over the age of 12 should not babysit a boy 9 or older, and a male over the age of 13 should not babysit a girl 3 or older. The prohibition of yichud makes some natural solutions problematic, e.g. when a teenage girl who might babysit her sister's son has to consider the possibility of getting into yichud with her brother-in-law. The situation may be evaded by the presence of another boy or girl aged 6–9, or, such children lacking, by giving a key to the neighbors and asking them to come in unexpectedly. If a father is single, or his wife is away, and he employs a female babysitter, he has to take care that he does not enter the house before the babysitter has exited, unless there are shomrim present; or else, at least he should leave the door open. Serious illness, on the other hand, does not alleviate the prohibition of yichud. An exception is, according to Moshe Feinstein, a male patient who has been diagnosed as impotent, but in this case marit ayin calls for carefulness. A dependent adult person in need of care should take a caregiver of the same gender. This applies also to very old men.

If a woman is traveling in a bus or taxi, and the other passengers get off, leaving her alone with the driver, she should leave the vehicle, unless they drive where there are passersby or a steady stream of traffic.

According to most poskim, there are no restrictions on being secluded together momentarily in a temporary environment, such as an elevator. Since elevators are boarded constantly, there is always a chance that anyone could enter without warning.

Business

thumb|250px|If a location can be viewed from the outside, there is no concern for yichud.

In a location of business, a male and female may be together for business purposes provided that the location where they are has the potential to be viewed from outside. Otherwise, the door has to be unlocked or people with a key allowed to come in unexpectedly. This applies also if they have separate rooms in the same office. A close working relationship excludes the possibility of relying solely on Baaloh B'ir. A man may temporarily be secluded with three women, but not on the basis of a permanent relationship. Two men who are prutzim (fail to keep the laws of tznius) are not allowed to work with two women. Neither may a woman work together with three non-Jewish men.

A male teacher should take heed that he does not become overly familiar with the girls. A male teacher who is single should not teach young children of either sex, since he may associate with their mothers when they come and pick up their children. In schools with many staff members, however, one may be lenient, and some poskim take the position that this halacha applies only to situations where the teaching takes place in the private home of the teacher.