The Catalans had drawn their last two matches to hand more momentum to league leaders Real Madrid but Sunday's win took them to 73 points after 34 games, four behind their arch-rivals who won 1-0 at Athletic Bilbao earlier on Sunday.
- Barca Ratings: Griezmann 8/10, Messi 9/10 in new formation
An own goal from Pau Torres put Barca in front in the third minute, with Villarreal's Gerard Moreno levelling on the rebound in the 14th before the visitors restored their lead through an outstanding curling strike from Luis Suarez six minutes later.
Antoine Griezmann stretched Barca's advantage just before the break with a sublime chip, having been dropped from the starting lineup in the last two games, while 17-year-old Ansu Fati added a fourth in the second half with a low strike.
Barca's confidence was rocked by draws with Celta Vigo and Atletico Madrid while the sense of instability at the club deepened amid reports captain Lionel Messi was unhappy with the state of affairs and did not want to stay beyond his contract.
There had been also been plenty of speculation surrounding coach Setien after he had brought Griezmann on in added time against Atletico, a move described in the Spanish media as an act of humiliation against the World Cup-winning forward.
Griezmann was named in the lineup against a Villarreal side who had won five of their last six games and was lively from the kick off, helping force the opening goal as well as working tirelessly in midfield and combining well with Messi and Suarez.
He adorned his performance with a sumptuous goal, receiving a back-heeled lay off from Messi and coolly delivering a chip that skimmed off the crossbar and into the net.
Messi also produced an outstanding performance but failed to score as the Argentine had one effort ruled out for offside after a thrilling team move and then hammered the bar with a late free kick.