According to Shulchan Aruch, (please cite Saeef and Siman so I can read further):
What are all the days we add Al Hanisim? (Just Purim and Hanukkah?)
What happens if we forget to say it?
One says Al Hanissim all 8 days of Channukah (ShA OC 682:1). One who does not live in a city walled from the days of Joshua or in Shushan says Al Hanissim on the 14th of Adar (ShA OC 693:2). One who lives in a walled city from the days of Joshua or in Shushan says Al Hanissim on the 15th of Adar, even if it falls on Shabbat when the Megillah is read on Friday (ShA OC 688:6). According to the Mishna Berura (OC 693 sk 6), one who said Al Hanissim on the wrong day of Purim for him does not have to repeat Shmoneh Esrei, and one who lives in a city whose status regarding Purim is uncertain says Al Hanissim both days (but CYLOR!). According to the Mishna Berura (OC 697 sk 1) one who said Al Hanissim on the 14th or 15th of Adar I does not need to repeat Shmoneh Esrei after the fact.
If one forgot Al Hanissim but is still in the middle of that blessing in which they would be said, he may go back and insert it, but if he already finished the bracha, he should not go back (ShA OC 682:1), but can say Al Hanissim after Bentching preceded by a special Harachaman formulation found in Bentchers (Rama ad loc). According to the Mishna Berura (OC 682 sk 4) one should do this as well following forgetting Al Hanissim in Shmoneh Esrei.