Q) Am I allowed to eat before hearing the megilla on Purim night? And what about having a coffee before Shacharis on Purim day?
A) Purim is usually preceded by Ta’anis Esther (the exception being when Purim falls on Motzo’ei Shabbos, or Purim in Yerushalayim which occurs on the 15th of Adar). Whereas on a regular ta’anis one is allowed to eat as soon as the ta’anis has concluded; on Purim there is another issue – namely, the prohibition of eating before performing a mitzvah, in our case the mitzvah of reading/hearing Megillas Esther.
The Shulchan Aruch (OC 692:4) rules that an individual who has difficulty in waiting until after hearing the megilla to eat, can hear the megilla from the time of plag hamincha. [This will allow him to eat immediately at nightfall; since he has already fulfilled his obligation of Megilla.]
The Remo (ibid) adds a statement that is really an introduction to the aforementioned ruling of the Shulchan Aruch: It is forbidden to eat before Megillas Esther; even if one has difficulty fasting. The Mishna Berura (s.k. 15) adds that this prohibition applies also to Purim day and even one who has already davened may not eat until he hears Megilla. [It should be mentioned that if one gets up before alos hashachar then one may eat and drink since the time of the mitzvah of Megilla has not yet arrived.]
We see therefore that there is a prohibition to eat before reading/hearing Megillas Esther; and according to the Shulchan Aruch it is preferable to precede the Megilla reading from plag hamincha than to eat before Megillas Esther.
The Magen Avraham (s.k. 7) discusses if it is permissible to “taste” a small amount of food before Megilla and concludes based on an inference from the Remo that “tasting” is permitted before Megilla. However, one may only be lenient in a situation of great necessity.
(The Magen Avraham also quotes the Maharil who rules that even a choleh may not eat before Megilla.)
The Mishna Berura (s.k. 14) quotes the conclusion of the Magen Avraham that “tasting” before Megilla is permitted. The amount of food that qualifies as a “taste” and is not called “eating” is the size of a beitzah regarding both food and drink . Therefore, the Mishna Berura rules that it is in fact preferable to taste some food before Megilla, than to precede the Megilla from plag hamincha (as the Shulchan Aruch advises) since according to some major Halachic authorities (Pri Chodosh and possibly also the Vilna Gaon) one who reads the Megilla before nightfall has not fulfilled the obligation of Megilla.
The Mishna Berura limits the leniency of “tasting” food to a person who is moderately ill or to somebody who has difficulty fasting. However, someone who is of a weak disposition and the delay in eating may cause him to ail (and “tasting” will not suffice) may eat normally provided that he appoints another individual as his shomer to remind him to hear the Megilla .
Returning to our original questions: the default position regarding eating or drinking before Megilla on both Purim night and day is that it is forbidden. An individual who is slightly ill or has difficulty fasting may “taste” an amount of food or drink that is less than the size of a beitzah. One who is weak and withholding from eating may cause him to ail may eat normally provided that he appoints a shomer who will remind him to hear Megilla.