Deon Hotto popped up with an 89th-minute header from close range in Monday's entertaining Group E opener for the impressive Brave Warriors, who continued a theme of upsets during the initial stages of the latest AFCON tournament in Ivory Coast.
It follows Cape Verde's stunning last-gasp victory over Ghana on Sunday, with seven-time winners Egypt also having needed a late Mohamed Salah penalty to avoid a shock loss to Mozambique.
Nigeria and Algeria were also held by Equatorial Guinea and Angola respectively in their opening matches as the bigger nations continue to struggle early on.
Hotto scored a second goal in stoppage time for Namibia at Korhogo's Amadou Gon Coulibaly Stadium, but that was rightly ruled out for offside.
The Orlando Pirates star was a thorn in Tunisia's side all evening, working marvellously in tandem with Namibia's captain and record scorer Peter Shalulile, who came close with several of his own opportunities either side of the break.
Namibia boss Collin Benjamin also had goalkeeper Lloyd Kazapua to thank for a string of five saves to keep Tunisia at bay and help condemn the Eagles of Carthage to a shock opening defeat that leaves them with plenty of work to do in a group that also contains Mali and returning South Africa.
Namibia had previously been to AFCON only three times, in 1998, 2008 and 2019, but had claimed only two draws and lost seven of their nine games on the biggest continental stage, until Tuesday.
Tunisia - without Sevilla's Manchester United loanee Hannibal Mejbri - had more than enough chances in what was an entertaining, end-to-end game for long stretches despite a lack of goals, most notably for captain Youssef Msakni, Elias Achouri, Montassar Talbi and Haythem Jouini, introduced as an early replacement for the injured Yassine Khenissi.
However, they could not find a way past Kazapua as head coach Jalel Kadri was left with a number of issues to correct quickly ahead of a key clash with Mali on Saturday night.