Madi Township () is a township in Longsheng Various Nationalities Autonomous County, Guangxi, China. As of the 2018 census it had a population of 15,100 and an area of .
Madi Township, formerly known as "Mati Township" (), because a large stone like horseshoe in the township.
As of 2016, the township is divided into eight villages:
It was incorporated as a township in 1984.
Madi Township is situated at northeastern Longsheng Various Nationalities Autonomous County. It borders Chengbu Miao Autonomous County in the north, Jiangdi Township in the east, Sishui Township in the south, and Weijiang Township in the west.
The economy is supported primarily by farming and ranching.
The Provincial Highway S219 is a south-north highway in the town.