סימן צז סעיף יא
אֵין לְקַדְּשָׁהּ קוֹדֶם תִּשְׁעָה בְאָב, וְכֵן כְּשֶׁהוּא אָבֵל אֶלָּא אִם כֵּן לֹא יַשְׁלִים אֲבֵלוּתוֹ עַד שֶׁיִּהְיוּ עֲשָׂרָה מֵעֵת לְעֵת מִן הַמּוֹלָד, אָז יְקַדְּשָׁהּ בִּימֵי אֶבְלוֹ. וְאֵין לְקַדְּשָׁהּ כְּשֶׁהוּא בְּתַעֲנִית עַד שֶׁיִּטְעַם מִקֹּדֶם. וּמִכָּל מָקוֹם בְּמוֹצָאֵי יוֹם הַכִּפּוּרִים, כֵּיוָן שֶׁאָז יוֹצְאִים מִבֵּית הַכְּנֶסֶת בְּשִׂמְחָה עַל מְחִילַת הָעֲוֹנוֹת מְקַדְּשִׁין אוֹתָהּ מִיָּד.
The moon should not be sanctified before Tisha B'av,21Ramah 426:2. Because sanctifying the moon is a mitzvah fulfilled with joy. and not when one is a mourner,22Mogein Avraham. unless his mourning period will not end within the ten full days23Ten 24 hour periods. after the appearance of the new moon. In such a situation, it may be sanctified during the days of mourning.24Mogein Avraham. But the Biur Halachah 426:2 says a mourner may not sanctify the moon unless the entire allotted time to sanctify the moon will elapse before the end of the seven days of mourning. The moon should not be sanctified on a fast day until some food has been eaten. But in any case after Yom Kippur, since we leave the synagogue in a joyous spirit, confident that our sins were forgiven, we sanctify it25Chayei Adam. After you taste something, you may sanctify the moon even immediately after Tisha B’av. (Mishnah Berurah, Achronim) If there is a minyan sanctifying the moon now and there will be none later, you should do it with them even if you have not yet broken your fast. (Sha’ar Hatziyun 426:9, Eliyohu Rabba) immediately.26Even before breaking your fast or putting on shoes. After Tisha B’av, however, you should first put on your shoes.
תנא דבי אליהו כל השונה הלכות בכל יום מובטח לו שהוא בן העולם הבא שנאמר הליכות עולם לו אל תקרי הליכות אלא הלכות (נדה ע"ג.)