The win extends Barca's lead at the top of the standings to four points over Real Madrid, who take on Celta Vigo on Sunday.
However, the game did not get off to the best of starts for the Catalans, who found themselves behind to an Antony goal in just the sixth minute.
The lead would only last five minutes, though, as Torres latched on to a Jules Kounde cross to level proceedings before putting them ahead two minutes later with an outstanding volley from outside the area.
Winger Rooney Bardghji got on the end of a Pedri pass to make it 3-1 at the near post in the 31st minute before Torres completed his first-half hat-trick nine minutes later with a pinpoint shot from the edge of the box to put Barcelona in a commanding position.
Lamine Yamal would make it 5-1 from the penalty spot 15 minutes into the second half before Real Betis began to fight back.
Diego Llorenta pulled one back in the 85th minute and Cucho Hernandez converted from the penalty spot in the 90th minute to make Barca sweat but ultimately they were able to hang on for a thrilling 5-3 win.
Elsewhere in LaLiga on Saturday, Alex Berenguer's 85th-minute strike was enough to hand Athletic Club a 1-0 win over Atletico Madrid, while Alaves beat Real Sociedad by the same margin, with Lucas Boye's penalty on the stroke of half-time proving to be the difference between the two sides.
Villarreal got the better of Getafe 2-0 with Tajon Buchanan (45+5) and Georges Mikautadze (64') providing the goals.