The Irish outfit raced into an early lead at Parc y Scarlets thanks to Danie Poolman’s try.
But Williams kept the scoreboard ticking with a twenty point haul and Joe Snyman crossed for his first try in Scarlets colours.
Mike Swift crossed for a late try but it was not enough for the men from the Emerald Island.
The victory sees the Scarlets climb back into the play-off places but Glasgow can regain their fourth place spot with a win against Zebre on Saturday.
The Scarlets shot themselves in the foot straight from the kick-off in Llanelli. They failed to secure possession and Connacht pounced.
Fetu’u Vainikolo took the ball up and former Cardiff Blues fly-half Dan Parks fired a cross-kick to the corner which Danie Poolman collected to score.
Owen Williams, who represented Wales at last year’s Junior World Championship, hit-back for the hosts and continued to exchange shots at goal with Parks.
And the youngster edged the battle to hand the Scarlets a 12-8 half-time lead.
The Scarlets appeared to stretch their lead when Gareth Owen danced through the Connacht defence to send Gareth Maule over the whitewash.
It was adjudged that the ball was held up but the Welsh region did not have to wait long as Snyman powered over.
Williams converted the effort and added a further penalty to put the result beyond doubt.
Connacht continued to battle and Swift powered over for a late try but it was merely a consolation.