The first time Ronald Wilson Reagan ran for office he was so underrated that the opposition did everything it could to make certain that he was the Republican nominee.

Five percentage points ahead in the last poll taken before that 1966 elections, Reagan was elected governor of California by 16 points. He has, ever since, been an underrated candidate, the kind of person whom people tell jokes about in the bar and vote for in the privacy of the polling booth.

As the pollsters and the pundits on both sides tried to explain what happened Tuesday, many of them still seemed to be underestimating Reagan.

It was, they said, President Carter's record or his inability to inspire traditional Democrats. Or it was the hostages issue, which a week before was supposed to have reelected the incumbent president. Or it was the economy, which in fact was beginning to take an upward turn, or the anticipated low voter turnout which proved not to be as low as expected.

All of the anti-Carter issues no doubt played a large part in Reagan's landslide victory. So, too, did a Reagan campaign which was well-financed and shrewdly exploitive of opposition weaknesses as well as the beneficiary of a vastly superior Reagan grass-roots political organization.

"But when you write your story, don't forget to mention the candidate," Reagan political strategist Stu Spencer advised a reporter on the campaign plane last week. "He is a helluva candidate."

And so he proved to be. In an age when politicians often appear seedy, suspect and unable to deliver on even the simplest of promises, Reagan stands out as something of a mythic figure. He is an actor and a cowboy identified with a lost America of the past. It is that America, as Reagan has been saying in his speeches for 16 years, that is "the last best hope of man on earth."

"You kid about him being an actor," says Keith Bulen, the veteran political professional who directed Reagan field operations in the East and Midwest. "But it's the greatest thing in the world. He has a rapport and a romance about him that people like. And he is a great communicator who puts things in a way that people understand."

Looking back from the mountaintop of Reagan's presidential victory, it seems strange that his acting background was again regarded by his opposition as a tempting political weakness. The nation, after all, has had a 70-year romance with Hollywood, and Reagan recognized it when he decorated his rallies with a host of aging actors, entertainers and celebrities.

Ordinary politicians are examined for their records. Mythic figures are regarded differently, no matter how many stories and television specials appear on the way they scramble their statistics or misidentify the governor who is supposed to be introducing them.

When Reagan's capble pollster Richard Wirthlin surveyed voters in September, he found that 40 percent of them didn't have any of what Reagan stood for despite the candidate's quarter-century on the banquet circuit and his nearly successful run for the Republican presidential nomination in 1976.

The Reagan campaign turned this apparent weakness into an asset in a key decision which chief of staff Ed Meese and pollster Wirthlin credit to ad man Peter Dailey.

"We kept talking about the California record until most of us in the campaign had become sick of it," said Wirthlin today.

Yet, what the ad celebrating Reagan's gubernatorial record was doing was informing voters that the Mythic Reagan's also was Governor Reagan, with a record of accomplishment in the nation's most populous state. The Wirthlin trackings started to show that as people became acquainted with Gov. Reagan they liked him as much or more as the Reagan they had heard about.

While this was happening, Carter was introducing the voters to a different Reagan -- a Reagan who was "dangerous" and "radical" and "belligerent". This was the Reagan who was the target of hostile demonstrators yelling "Reagan for shah" or bearing posters which declared "Reagan -- Fascist Gun in the West."

The extent of Carter's attacks caught the Reagan campaign by surprise and put the Republican nominee on the defensive. At first, no one knew what to do within the Reagan organization.

It seemed to many in the beginning of October that Reagan was becoming discredited. On Wirthlin's day-to-day trackings, in which Reagan had held a slight lead through most of September, Carter actually pulled ahead by a single point near the first of the month. Then, voters began to react against the president.

"People thought of President Carter as a good, moral, kind, Christian man," said Wirthlin. "He threw away a precious asset and got very little in return for it."

The final decisive event in Regan's campaign -- many would say it was the most decisive -- was the presidential debate in Cleveland Oct. 28.

When Reagan and his aides, led by Micheal K. Deaver and Spencer, decided on Oct. 19 to accept the debate challenge, the Reagan campaign was flattening out with a 5-point lead. Looking ahead, Reagan's strategists saw Carter scoring points on Reagan's refusal to debate. They also thought that the return of U.S. hostages from Iran, if accomplished before the final days of the campaign, had the potential to turn the election around.

Acceptance of the debate stopped the Reagan slide, as undecided voters waited for the confrontation to make up their minds. And the debate itself undercut Carter's argument that Reagan was "dangerous." No matter what the president said, viewers didn't believe it when they saw the two candidates side-by-side.

"We would have won the election without the debate," said Wirthlin, who had been dovish on the debate issue. "But the debate provided the platform for the jump that occured."

Reagan went up from 5 to 7 points the day after the debate. Then he soared in the surveys near the end of the week as he began to attack Carter. The nature of the attack, introduced in Reagan's closing debate statement, was a series of rhetorical questions asking voters whether they were economically better off or whether the nation was more secure or whether they were happier because of the Carter presidency.

When the year began, Reagan seemed the oldest and most vulnerable of candidates. The Carter White House could scarcely conceal its glee at the prospect that he would be the Republican nominee. Reagan was too old, too out-of-touch, too conservative. Even close aides acknowledged that he was hard of hearing. His early campaign, oblivious to the limiations imposed by federal law, wasted so much money that the candidate was in danger of going broke by April. Reagan changed campaign managers and press secretaries and political directors, and the logistics of key sections of the campaign sputtered from the beginning to the very end.

But Reagan has always been a kind of fourth-quarter candidate, a competitor who starts slowly and comes on strong.

In 1966, he lost his cool and walked out of a meeting with black leaders in the early part of the coampaign. In 1976, he spent much of his time trying to explain what he had really meant to say in a speech where he talked about turning $90 billion of federal programs back to the states.

In both campaigns, he was a dynamite candidate near the end, as he was again this time.

Reagan's start in 1980 was not promising. He blew the Iowa caucuses by failing to show up for a debate and then devastated Iowa winner George Bush in New Hampshire when he proclaimed ownership of a microphone in a celebrated confrontation in Nashua.

In August, as the Republican nominee, Reagan discovered that the Vietnam War was a "noble cause" and then found some flaws in the theory of evolution.

But in October, when it counted, Reagan was once more the mythic candidate who evoked memories of a better America that had been and hope of a better America to come.

"I find no national Malaise, I find nothing wrong with the American people," Reagan said in his televised election-eve address. "Oh, they are frustrated, even angry at what has been done to this blessed land. But more than anything they are sturdy and robust as they have always been."

Reagan, at 69 years old, was sturdy and robust, too. In fact, he was at the end a far stronger candidate than he had been when his managers were resting him and keeping him out of the debate in Iowa 10 months before.

When Election Day came, after all the strategizing and all the name-calling, it was Reagan's election. This time, it was the Gipper who won one for himself.