BOSTON -- Massachusetts Gov. Michael S. Dukakis has virtually abandoned hopes of a quick knockout victory in Iowa and is searching for a message that will give some lift to the dogged campaign he is prepared to wage for the Democratic presidential nomination.

The quest for an inspirational speech that is comfortable and credible for the managerial-minded state executive preoccupies the campaign more than any fear of the revived candidacy of Gary Hart.

With the Iowa Democratic debate coming up in Des Moines on Friday, Dukakis' private polls show him trailing Sen. Paul Simon (Ill.) and being crowded by the other neighboring candidate, Rep. Richard A. Gephardt (Mo.).

"There is enough volatility" among Iowa Democrats, said campaign manager Susan Estrich, to justify an all-out organizational effort for the Feb. 8 caucuses, but Dukakis will invest less of his personal time there than Simon, Gephardt or former Arizona governor Bruce Babbitt, all of whom need a strong Iowa showing to sustain their credibility in New Hampshire eight days later.

"Lightning could strike," she said, "but you don't base your campaign strategy on that happening."

Dukakis told Florida backers Friday that "no one expects me to finish first in Iowa," but there is great confidence among his strategists here and supporters in New Hampshire that he will rebound to beat the field -- including Gary Hart -- in New Hampshire's leadoff primary.

With good prospects in Maine and Minnesota, the major states with February contests following New Hampshire, his managers believe Dukakis should go into the March 8 "Super Tuesday" contests with enough momentum to challenge the southern cofavorites, Jesse L. Jackson and Sen. Albert Gore Jr. (Tenn.), who can count on no show of strength in the first half-dozen contests.

Robert Farmer, who raised a Democratic record $10.5 million for Dukakis in 1987, said "ours is the only campaign that can plan a serious media buy" in all 20 states voting that day. Dukakis is also the only candidate already with staff in all those states. He has more than 40 paid staff members in the targeted states of Texas, Florida and North Carolina, which will elect more than half the southern delegates. With his delegate total likely to be boosted by contests that day in Massachusetts, Maryland, Rhode Island and Washington state, "we can not only survive but prosper" on Super Tuesday, political director Paul Jensen said.

The major concern is finding a message that Dukakis can take nationally into the Super Tuesday states and the major remaining battlegrounds such as Illinois, Michigan, New York, Pennsylvania, Ohio, California and New Jersey.

"It's not a problem in the early states," Jensen said. "Dukakis is seen as a very credible, electable guy in Iowa, New Hampshire, Minnesota and Maine. The challenge is to have the message so clearly established that when the field is narrowed, his position is defined by him and not by someone else."

For most of 1987, Dukakis talked about the "Massachusetts economic miracle" of technology-driven growth and low unemployment as his main credential.

But his strategists recognized he needed something between the parochialism of the economic speeches and the globalism of the speeches designed to establish his credentials in foreign policy. "We showed Michael's competence," Estrich said last week, "but we understood we had to put it in the larger context of where the country has been and where it is going."

The urgency of the need is reflected in Estrich's comment that "on the night of our first wedding anniversary {last Nov. 29}, I turned over in bed and said, 'Marty, we need a new stump speech.' "

Her husband, Marty Kaplan, a movie executive who served as a speechwriter for Walter F. Mondale in 1984, came up with a draft, which was heavily reworked by Dukakis and others, and introduced in Texas just before Christmas.

Last Tuesday, Dukakis gave it for the fifth time, to supporters in Nashua, N.H., at a session designed largely to produce film for commercials. The speech began by defining the election issue in national terms -- how to deal with "the accumulated baggage of the Reagan era" -- and did not mention a Massachusetts program example until the 36th paragraph of a 49-paragraph text.

It was difficult to judge its effectiveness. Staff members in the back of the college auditorium started the infrequent bursts of applause in the first third of the talk. Then Dukakis drew spontaneous cheers with such sure-fire Democratic themes as praise for teachers, promises of better health care, and denunciations of "Star Wars" and contra aid.

In the last few weeks, outside media experts such as Tom Kiley, Ken Swope and Francis O'Brien have been brought in to sharpen Dukakis' message. But campaign veterans concede privately that the effort can be "frustrating."

Dukakis has resisted an all-out populist appeal to angry and alienated voters, such as Simon and Gephardt are making, because, Estrich said, "he really is optimistic about this country and its future." His new stump speech ends with language President Reagan often uses, defining himself as one "who believes in the American dream" because "I'm a product of that dream."

Some of his advisers say privately that Dukakis' reluctance to give full voice to the economic frustrations many Iowa Democratic caucus-goers feel is one reason Simon has passed him there and Gephardt is threatening to do so.

The compensation, they say, is that Dukakis will not have to reposition himself for campaigning in high-growth states such as New Hampshire, North Carolina or Florida or the prospering industrial states from Maryland to California, where populism may have a more limited appeal.

Whether Dukakis can frame a broad and energizing nonpopulist appeal is a harder question, some advisers concede. "Michael is a very concrete, task-oriented guy," one said. "He thinks his values are implicit in the programs he's achieved. We have to find a way he can make those values clear to people who don't know that much about his record."

New Hampshire is not likely to test that ability. Simon's challenge has developed enough credibility that some of his enthusiastic supporters talk of his riding an Iowa victory to an upset of Dukakis in New Hampshire.

But Simon said Friday that as a "political realist," he thought it unlikely he could beat a neighboring governor "with nightly exposure on Boston television news programs reaching 82 percent of the New Hampshire voters." Still, Simon is regarded in the Dukakis camp as a greater potential threat in New Hampshire than Gephardt or Hart.

But such Dukakis strategists as Jensen utterly dismiss the possibility that Dukakis' support might collapse as front-runner Mondale's did in the final week of the 1984 New Hampshire campaign.

"There's a huge difference in the firmness of Dukakis' support and Mondale's," said Jensen, a Mondale campaign veteran. "As governor, he has taken positions on many issues like Seabrook {the nuclear power plant} that are well known and of great consequence to New Hampshire. He is not an interloper."

But he is an outsider in most of the states that follow New Hampshire, and there "the message problem" could prove consequential.