The Seagulls were in danger of slipping out of the top six after Ulloa’s opener was cancelled out by James Vaughan before half-time.
But the Argentinian striker, a January signing from Spanish side Almeria, struck twice more in the space of three second-half minutes before David Lopez wrapped up Brighton’s third straight win from the penalty spot.
Gus Poyet’s side looked destined for the play-offs last season only to slip away during the run-in, but this term they look like they mean business.
The hosts dominated the opening stages but only had Ulloa’s 20th-minute goal to show for it.
Will Buckley’s header from Lopez’s corner was kept out by Town keeper Alex Smithies and Adam Clayton blocked a header from Ulloa.
But the breakthrough came from another Lopez corner which was volleyed towards goal from the edge of the area by Buckley.
Oscar Gobern blocked the fierce effort but the ball fell to Andrea Orlandi, who whipped in a near-post cross which Ulloa met with a fine header.
Orlandi almost made it two after a quickly-taken free-kick by Buckley but his shot was superbly tipped around a post by Smithies.
And the Seagulls were hit by a sucker-punch three minutes before half-time when, on a rare Huddersfield foray forward, Gobern crossed from the right and Vaughan finished from close range.
But Smithies was finally beaten again in the 75th minute when Ulloa met Lopez’s cross with a powerful header from 12 yards out.
And three minutes later Ulloa latched onto a long pass from Inigo Calderon, rounded Smithies and rolled the ball into an open goal to complete the Seagulls’ first treble at the Amex Stadium.
Brighton made it four in the 80th minute when Paul Dixon brought down Craig Mackail-Smith in the area and Lopez coolly tucked in the penalty.