Lee Novak had fired Terriers level late in the second half after former Huddersfield midfielder James Berrett had given Carlisle the lead just after the break.
Substitute Alan Lee could have won it for Huddersfield just seconds before Miller’s late intervention when he shot past Carlisle goalkeeper Adam Collin only to see his effort bounce back off the post.
Carlisle’s 46th-minute opener was the result of a slick passing move down the right and a good cross from Frank Simek. Berrett timed his run into the box perfectly to slid the ball under goalkeeper Alex Smithies from eight yards.
Terriers’ equaliser in the 80th minute came from Lee’s low ball, driven across the face of goal to the far post, where Novak sidefooted home with Collin stranded.
Both sides had chances in a thrilling finale and after Lee had gone agonislngly close for Terriers, Danny Livesey’s
long ball was backheaded home by Miller, who beat the advancing Smithies to the ball on the edge of the six-yard box.