After a goalless first half, midfielder Carles Alena, 21, opened the scoring with a close-range finish following a sweeping attack by the visitors.
Barcelona were awarded a penalty soon after following a VAR handball review and Uruguay’s Luis Suarez converted.
Victory means Barcelona will be confirmed as champions on Wednesday if Atletico Madrid lose to Valencia.
The reigning champions are 12 points clear of Atletico, who have five games remaining.
While Atletico could potentially still finish level on points with their title rivals even if they slip up on Wednesday, Barcelona will win the title by virtue of a better head-to-head record between the two sides.
The result may mean Barcelona coach Ernesto Valverde rests players against Levante at the weekend before next week’s Champions League semi-final with Liverpool.
Valverde perhaps already had one eye on the first leg against Jurgen Klopp’s side on Wednesday by opting to start Lionel Messi on the bench at Alaves.
The Argentina forward came on just after an hour and went closest to scoring his 34th league goal of the season with a powerful strike from a tight angle that was tipped over by Alaves goalkeeper Pacheco.
By Hussein Ganiyu