Niger borders seven countries and has a total perimeter of . The longest border is with Nigeria to the south (). This is followed by Chad to the east, at , Algeria to the north-northwest (), and Mali at . Niger also has small borders in its far southwest with Burkina Faso at  and Benin at  and to the north-northeast Libya at .