The Rabbis taught: "The mitzvah of the Chanukah candle is to place it in the outer part of the doorway of the house" (Shabbat 21b). This is when the door of the house opens onto a public thoroughfare, but if it opens onto a private yard, the candle is to be placed by the front gate of the yard (Tosafot). Rashi comments that the reason why the candle should be outside is to publicize the miracle of Chanukah. Unlike Tosafot, Rashi deems it sufficient to set it by the door of the house even when the door opens on to a yard.
Where in the doorway do we place it? At the left side, so that the mezuzah is to the right of the person lighting and the Chanukah candle is to his left (Shabbat 22a). The Tur, the halachic work of Yaakov ben Asher (ch. 671), writes that if for some reason the doorway does not have a mezuzah, the Chanukah candle should then be placed on the right side.
We must try to understand:
Without the candle of mitzvahs to dispel the darkness there can be no light…
1) Why the most important thing is for the Chanukah candle to shine towards the outside (either to the public domain or to the yard - unlike the mezuzah, it has no intrinsic connection to the door of the house).
2) What is the significance of placing the Chanukah candle on the left side?
3) Since the Gemara states that the reason the Chanukah candle is placed at the left side of the doorway is in order to be opposite the mezuzah on the right, this indicates that there is a relationship between the two objects (and only when there is a mezuzah is the candle placed at the left; otherwise it is put on the right). What is this relationship?
Before we can understand the above, we must first consider the verse "For the mitzvah is a candle and the Torah is light..." (Proverbs 6:23). Just as physical light is generated by a candle, the light of Torah is generated by a mitzvah candle. Without the candle of mitzvahs to dispel the darkness there can be no light of Torah! Through the mitzvah candle we attain the Torah light, which is the inner light of the Essence of G‑d - the source of light that has to shine below in order to transform the spiritual darkness of this world into light.
Briefly, the explanation of this is as follows: Mitzvahs can be performed only with physical substance. For example: tsitsit [tallit fringes] are made of physical wool, the Four Species waved on Sukkot are physical plants, and a mezuzah is written on physical parchment. Through doing mitzvahs with physical objects we can transcend the separateness of the physical that we perceive with our senses and realize our true nothingness in relation to G‑d: that the created existence is nothing and the Creator is the true existence. Then G‑dliness can be revealed through us and to us.
When we meditate upon the verse "I, G‑d have not changed" (Malachi 3:6), we understand that the apparent change (during Creation from spiritual into physical through the concealment of the spiritual) is only from our perspective; from G‑d's perspective, however, there is no darkness or concealment of His Infinite Light.
We contemplate further and we intellectually realize that even from our perspective there is no darkness and no concealment - only G‑d's Infinite Light.
Thinking about this truth evokes within us an intense desire to actually experience it. How can we accomplish this? Through learning Torah, the embodiment of G‑d's wisdom and will in this physical world, and through fulfilling the mitzvahs, G‑d's inner will (especially when we do so with joy).
Now we can understand why the Chanukah candle is placed outside the doorway, on the left side. The Greeks wanted to contaminate the wisdom of the Torah…
The Greeks defiled all the oil in the Temple chambers. Wisdom is compared to oil. The Greeks wanted to contaminate the wisdom of the Torah (Divine wisdom) with their intellectual wisdom. The positive wisdom of the Torah brings about a level of self-nullification that enables the one who learns it to fulfill Torah and mitzvahs and generally be a good person. One the other hand, the negative wisdom of the Greeks brings the one who learns it to feel himself to be a separate existence. He does whatever he wants to do, rather than what G‑d expects of him. The Greeks wanted to neutralize the positive wisdom, the True Reality, with the negative wisdom, the perceived reality. They wanted to make the Jews forget that the Torah is G‑d's Torah, and to deny G‑d's existence by not allowing the Jews to do the chukim (statutes), those mitzvahs decreed by the Torah which cannot be understood (and rationally justified) by human intelligence.
The Hasmoneans (Maccabees) overpowered and defeated the Greeks through their complete devotion to G‑d, to the extent that they gave up their lives (their existence) to reveal G‑d's existence (the idea of the mitzvah candle, see above). Afterwards, they instituted the lighting of the Chanukah candles, which is the same idea as the Torah light. The Chanukah candle is a revelation of the light of the future redemption…
The Chanukah candle is a revelation of the light of the future redemption, the light of the essence of G‑d, the light which automatically dispels and transforms the darkness. This is why the Chanukah candle must be placed outside the door facing a public area. The outside, the domain of the public, reflects the idea of plurality, of separate existence. The Chanukah candle contains the capacity to light up even the realm that represents a denial of G‑d's existence and a rebellion against Him. This darkness is automatically nullified by the light of Chanukah.
The source of the negative forces is the left side. The Chanukah candle is placed on the left and shines towards the left; it lights up the negativity (darkness) of the left side.
Rashi rules that it is permissible to put the Chanukah candle outside a front door that opens to a yard. The numerical value of the Hebrew word for yard, chatzer, is equivalent to that of bina-gevura-hod (understanding, severity, splendor), the three divine attributes (sefirot) of the left "line" (when they are schematically configured in the "tree of life"). Therefore, whether the Chanukah candle faces the public domain or the yard, it still accomplishes the same thing.
This (effect of the Chanukah candle being placed on the left) is operative only if there is a mezuzah affixed on the right. Mezuzah is considered equivalent to all the mitzvahs combined. The mezuzah on the door of a house shows that everything in the house is nullified before G‑d (that everything in it is for the sake of G‑d). It is on the right side, the side of holiness, the right that attracts. It brings the physical close to the Divine and enables it to be nullified before G‑d. Thus, we see that the mezuzah expresses perfectly the idea of the mitzvah candle. First we need to have the mitzvah light of the mezuzah on the right, and then we can have the Torah light of the Chanukah candle on the left.
If there is no mezuzah on the right we put the Chanukah candle on the right, because it is also a mitzvah. In such circumstances, placing the Chanukah candle outside on the right is enough to reveal the light of Torah.
[Adapted from a discourse on Shabbat Chanukah 5643/1882.]