Chadian President Idriss Deby. [Reuters]

Chad’s President Idriss Deby has died while visiting troops on the front line of a fight against northern rebels, an army spokesman said on Tuesday, the day after Deby was declared the winner of a sixth term in office.

Deby's campaign said on Monday that he was headed to the front lines to join troops battling "terrorists".

Rebels based across the northern frontier in Libya attacked a border post on election day and then advanced hundreds of kilometres south across the desert.

Deby, 68, came to power in a rebellion in 1990 and is one of Africa's longest-serving leaders.