Algeria will now meet Nigeria in the semi-finals at the Cairo International Stadium on Sunday as they seek to end their long wait for continental success that stretches back to 1990.
Sofiane Feghouli put Algeria ahead in the first half, but they failed to increase that advantage when Baghdad Bounedjah missed a penalty early in the second period.
Ivory Coast striker Jonathan Kodjia equalised just past the hour mark, after which both sides created chances and had efforts cleared off the line, but were unable to be separated in 120 minutes.
Bony saw his weak penalty saved by Algerian goalkeeper Rais M’Bolhi, before captain Die struck the post to sink the 2015 Nations Cup champions and see the North African side advance to just a second semi-final in 29 years.
Tunisia ended Madagascar’s remarkable Africa Cup of Nations run when they beat the rank outsiders 3-0 in their quarter-final on Thursday, notching their first win of the tournament in the process.
Madagascar, a country with little football tradition and who had not been expected to progress beyond the group stage on their first appearance at the finals, held out until the second half when they were undone by Ferjani Sassi’s deflected shot.
Youssef Msakni added a second on the hour for the Carthage Eagles, ranked 25th in the world against Madagascar’s 107th, and substitute Naim Sliti finished it off on the break in stoppage time to earn them a semi-final against Senegal on Sunday.
Tunisia had drawn their previous four matches at the tournament, beating Ghana on penalties in the last 16.