The United States continued to run a massive foreign trade deficit last month, with no change in the level of oil imports, which have plagued the trade balance for the past two years, the government reported yesterday.

Commerce Department figures showed the deficit for November officially at $2.08 billion - technically a drop from the record $3.1 billion red-ink figure recorded in October.

However, analysts said there were strong indications the deficit would have been substantially higher if imports hadn't been impeded by the East Coast and Gulf port dockworkers' strike that was settled in late November.

Courtenay M. Slater, the department's chief economist, said the apparent decline in the deficit "probably does not indicate a basic change in the pattern of trade," and that the red ink figure most likely would swell again.

She predicted the trade deficit for the year still would approach the $27 billion level the agency had forecast earier. By contrast, the deficit for all of 1976 was $5.87 billion.

The November deficit marked the eighteenth in a row, in what has become an increasingly volatile political symbol for the Carter administration. The White House wants to pursue an essentially free-trade economic policy; but has been under pressure to impose protectionist measures.

The trade pattern for the past two months has been distorted by the dock strike, which depressed exports in October and held imports down last month. Some imported goods were shipped to Canada and transported here by truck.

Officially, yesterday's figures showed a moderate rebound in exports, which rose by $114 million, or 1.2 per cent. Meanwhile, imports declined during the period by a sizable $901.5 million, or 7.3 per cent, mostly because of the dock strike.

Significantly, however, petroleum imports remained virtually unchanged. Oil import levels totaled $3.529 billion - a scant $29.7 million below October's level. Experts expect the oil import level to continue for the forseeable future.

The burgeoning trade deficit has been a key factor in the decline of the dollar in relation to foreign currencies recently. Officials say, however, they cannot do much about the red ink figure until the nation finds a way to reduce its oil consumption.

The November figures brought total import volume to $11.39 billion, reflecting decreases in imports of transportation equipment, machinery; sound recorders and reproducers clothing, furniture, toys games and sporting goods rubber and plastic goods, footward and other products.

Exports totaled $9.304 billion. Increases were recorded in overseas shipments of corn, rice, animal feeds, grain sorghums; iron and steel; transistors and semiconductors; office machines and parts and agricultural equipment.

The $2.08 billion deficit was calculated on a so-called "free alongside ship" basis, which represents only the transaction value of imports at the port from which they were shipped.

Although the November deficit figure was distorted by the dock strike, it still was one of the largest in history. A year ago, the U.S. posted a $1.03 billion trade deficit. Most this year have been in the $2 billion range.