Former Northampton striker Parkin headed wide from a Paul McVeigh cross early on and Calvin Andrew was denied by Mark Bunn before the Cobblers went ahead from a 34th-minute penalty.
Poul Hubertz was pulled back by Sol Davis and picked himself up to slam home the spot-kick.
Liam Dolman almost doubled the Cobblers’ lead but Don Hutchison cleared his header off the line.
Parkin was denied by Bunn late in the first half before Alex Dyer headed the hosts further in front from a Daniel Jones cross.
Andrew shot wide for the resurgent Hatters and was off target with a header. Darren Currie and Matthew Spring were then thwarted by Bunn who then denied McVeigh effort, before Parkin netted on 90 minutes.