The 27-year-old was loaned out to Darlington last season when he scored nine goals in 23 games, including two in the Quakers' 5-1 win over the Hatters in January.
Hatch was transfer listed by Peterborough following their promotion from League One and Luton have an option to sign the striker on a permanent deal.
"It's a player we've trailed for a long, long time," boss Mick Harford told the club's official website. "He's had success wherever he's been and it's fantastic that we've got him here.
"It was always our aim to get a player of Liam's ability to the club. He'll be a massive influence for us and a striker that will compliment the other forwards we have at the club in Tom Craddock, Ryan Charles and Kevin Gallen.
"Liam is ready for the challenge and is desperate to play for us."