The Cobblers are bottom of the table after losing their first four games of the season.
Assistant manager David Kerslake will take temporary charge of the side.
Northampton defeated Cambridge 5-4 on penalties in the EFL Trophy Southern Group H game on Tuesday, but it was not enough to save their 47-year-old manager.
Northampton chairman Kelvin Thomas said: "Justin did a good job for us in difficult circumstances and achieved what was asked of him when he came in last season by retaining our League 1 status, for which we will always be grateful
"However results overall haven't gone as well as any of us would have liked, but Justin is an honest and hard working individual and we wish him well for the future
He added: "David Kerslake will take temporary charge of the squad as we begin discussions to find our next manager.
"We do have some potential targets in mind and with a free weekend this weekend it does allow us some time.
"It is important that the focus of the squad is now on the game with Doncaster Rovers at Sixfields on Saturday, September 9th."
Source : PA
Source: PA