The 29-year-old Asturian striker's 45th and 46th goals for his country on his 72nd appearance made him the nation's leading scorer in his own right, two clear of Raul, who won his 102nd and last cap for Spain in 2006.
Nicknamed "el guaje", or "the kid", Villa's five goals in South Africa last year helped the Iberian nation to their first World Cup triumph and he was the leading marksman at Euro 2008 when Spain won their second continental championship.
After netting from the edge of the area to put the home side level in the 73rd minute in Granada, Villa raced across the pitch to embrace his friend and reserve goalkeeper Pepe Reina.
He grabbed the winner from the penalty spot four minutes later as Spain maintained their perfect record in Group I with four wins out of four.
"I really wanted it [the record], especially because it was a very tough match that did not start as we had hoped," Villa told reporters.
"I promised Pepe, who is my friend, a while ago that the goal that exceeded Raul's tally would be for him and I went over to dedicate it to him."
Spain's 10th victory in a row in competitive games since they lost to Switzerland in their opening match at last year's World Cup puts them in firm control of the group ahead of Tuesday's trip to Lithuania.
They are on a run of 18 straight qualifying victories since a 1-1 draw against Iceland in September 2007 and have not lost in 23 qualifiers since a 2-0 reverse against Sweden in 2006.
Friday's match was the 100th cap for Spain playmaker Xavi, Villa's Barcelona team mate whose domination of possession and distribution of the ball in midfield has been a crucial element of the recent successes of his club and country.
"I am happy, pleased to have got to 100 games, but also filled with a desire to continue participating and playing in this team, in which I have a magnificent role right now," the 31-year-old said.
Get the best features, fun and footballing frolics straight to your inbox every week.
Thank you for signing up to Four Four Two. You will receive a verification email shortly.
There was a problem. Please refresh the page and try again.