One of the ways we sanctify the holy Shabbat is by distinguishing it from the mundane weekdays which precede and follow it. With the onset of Shabbat we mark its entry by taking a cup of wine and blessing and expressing our gratitude to the One who sanctified the Shabbat, bequeathing this precious gift to His treasured nation. When the Shabbat departs on Saturday night, we do the same. Over a cup of wine we bless the One who separates the Shabbat from the rest of the weekdays.

There is difference of opinion between the halachic authorities whether the mitzvah of reciting the havdalah is biblical, or a rabbinical ordinance. The common consensus is that the obligation of reciting the havdalah blessing specifically over a cup of wine is certainly a rabbinic institution.

Over a cup of wine we bless the One who separates the Shabbat from the rest of the weekdaysIn anticipation of this special mitzvah, it is forbidden to eat or drink from sunset of Saturday evening until the havdalah over wine has been recited. Drinking water is technically allowed during this time, however it is the custom in many circles to abstain from this too.

The exception to this rule is continuing a meal which started before sunset. Such a meal may continue well into the night. At the Grace after Meals of such a meal, the retzay (Shabbat insert for the Grace after Meals) is recited even if it is long after nightfall. With the conclusion of the meal, it is forbidden to eat again until after havdalah.

Aside for the havdalah recited on a cup of wine, a brief section, attah chonantanu, is added to the Saturday night amidah. In this prayer we acknowledge that G‑d separates between "sacred and profane...the Seventh Day and the six weekdays." We further implore G‑d to bring us a week of "peace, devoid of all sin, cleansed of all wrongdoing and devoted to the fear of [Him]."

There were times in history when poverty was so rampant that the average person couldn't afford to purchase wine for havdalah. The rabbis then established this prayer in lieu of havdalah over wine. Even after the situation improved, they did not see fit to put an end to the recitation of this prayer.

Today too, this prayer serves a practical purpose as well. Even after nightfall of Saturday night, it is forbidden to do any activity prohibited on the Shabbat before verbally "separating" between Shabbat and the weekday. After reciting the attah chonantanu this has been accomplished, and it is permitted to do "creative labor" even before making havdalah over wine. Women, many of whom do not pray the evening prayer, can begin performing weekday activities after saying "Baruch hamavdil bayn kodesh l'chol" — "Blessed be He who separates between the sacred and the profane."