Updated

Fernando Alonso gave the home fans exactly the kind of daring and dominant drive they came to see. Keeping them celebrating at the end of the season might be a bit more difficult.

Alonso won the Spanish Grand Prix with a commanding performance Sunday, but then said Ferrari still needs a more pace to beat three-time defending champion Sebastian Vettel in the race for the Formula One title.

Alonso was fifth on the grid but used an aggressive start to take control and beat Kimi Raikkonen of Lotus by nearly 10 seconds, with teammate Felipe Massa 26 seconds behind. More importantly, Vettel was a distant 38.2 seconds back in fourth, meaning Alonso cut the gap to 17 points in the overall standings after five races.

With two Ferrari drivers on the podium and none from Red Bull, Alonso still cautioned that the Italian team hasn't caught up to its main rival.

"Last year we didn't win (the championship). We were one second off (the pace), but we managed to fight until the Brazil race," said Alonso, a two-time former champion. "This year we have a package that is still not the fastest but we are working on it."

Alonso lost out to Vettel by three points last year, but will head to Monaco in two weeks with high hopes.

"We are not the quickest over one lap, we maybe do not set the fastest time in the race, but we have fantastic pit stops, starts, (limited) tire degradation," said Alonso. "Many ingredients to have a competitive car to fight for the championship ... In the four years with Ferrari this is the best (car) we've had."

Ferrari team boss Stefano Domenicali dedicated the day to those working behind the scenes to make Ferrari faster.

"For sure, very, very happy. It was a good day for the team," Domenicali said. "The win was for the people who are working hard at the factory."

The race was once again heavily affected by Pirelli's fast-degrading tires, which forced teams into four-stop strategies when they had planned for three.

"Our aim is to have between two and three stops at every race, so it's clear that four is too many," Pirelli motorsport director Paul Hembery said. "In fact, it's only happened once before, in Turkey during our first year in the sport."

There is no time for Pirelli to make changes in time for Monaco.

"We'll be looking to make some changes, in time for Silverstone," Hembery said. "To make sure that we maintain our target and solve any issues rapidly."

Red Bull struggled a lot more than Ferrari with the tires, and the mood in the team's camp was subdued after the race.

"The first three cars were a little bit too fast for us and regarding looking after the tires, they did a better job," said Vettel, who finished ahead of teammate Mark Webber. "We need to catch up; we're not going the pace of the car, we're going the pace of the tires and obviously we do something to make the tires wear more. The start was good, we then tried to hold on with a three-stop strategy, but had to change to four stops."

Raikkonen finished second for the third straight race.

It was Alonso's second win in Barcelona — the first coming in 2006 — and his seventh career podium on the Circuit de Catalunya.

"It's very special winning at home and it doesn't matter how many times you repeat it," said Alonso, who moved up to third overall, while Raikkonen is only four points behind Vettel.

Massa's performance was arguably even better than Alonso's, as he started from ninth due to a grid penalty in qualifying.

"I think we are in the right direction so I hope from now on we are fighting for the podium in every race," Massa said.

Mercedes had a disappointing day after Nico Rosberg and Lewis Hamilton started on the front grid. As has been the case this season, the Mercedes cars — which are fast in qualifying — again lacked race pace and durability as Rosberg finished sixth and Hamilton drifted way back to 12th.

"There's a growing gap to three teams ahead of us which we need to get on top of," Rosberg said. "We have a very quick car but we have to make it work for us in the race."

Lotus driver Romain Grosjean's back wheels locked up early on and he had to pull out due to mechanical failure.

Caterham driver Giedo van der Garde's left rear wheel came off entirely and he also had to retire.

It was a busy afternoon in the pits as Sauber released Nico Hulkenberg too early and he bumped into the back of a Toro Rosso and with Pastor Maldonado — last year's surprise winner — pitting in the wrong place.