In a referendum that could be decided by a few thousand ballots on remote islands, the people of Micronesia will vote today on a constitution giving them partial independence after 31 years under U.S. control.

On the eve of the voting, the outcome is far from certain. Divisions among the island people could mean that the vast Pacific territory will split up with about one-third of them going their own way.

If enough people approve, the referendum would create a new Federated States of Micronesia, a partially sovereign nation that would govern its own internal affairs but share control over foreign affairs with the United States.

The United States would retain defense responsibility for at least 15 years in an area it has long wanted to transform into a security bastion in the western Pacific.

The proposed "free association" arrangement represents a partial defeat for American interests, which once were directed at keeping tighter control over the strategically important Pacific islands. After nine years of negotiations, culminating in a major policy change last April, the United States accepted the new arrangement because, in the words of the U.S. official here, "It's just the best we could do."

The islands figured prominently in the middle stages of the Allied offensive against Japan during World War II.

Starting with an invasion of Kwajalein in early 1944, followed by a naval probe at Truk which found defenses there so weak that the island could be by-passed, the campaign reached Saipan in June 1944. There, U.S. Marine and Army units needed several weeks to overcome stiff Japanese resistance. The island offensive opened the way for retaking the Philippines and provided bases for the sustained bombing campaign against the Japanese mainland.

Micronesia is the last of the 11 U.N. trust territories established after World War II. All of the others have voted themselves either independence or association with some other country. Micronesia came under U.S. control as a U.N. trust territory.

Part of Micronesia, the Marianas, already has voted for commonwealth status with the United States and the question now is what will happen to the remainder - the Carolines and Marshalls.

Some 2,000 islands scattered over waters the size of the United States but containing only 110,000 people are involved. About 60,000 are eligible to vote and because of the vast distances the results may not be known for two weeks, after all the ballot boxes are collected from the more remote islands by boat and airplane.

The islands are divided into six voting districts, at least four of which must approve the constitution if the federation is to get off the ground. If less than four approve it, the U.S. trusteeship would continue until some new arrangement is negotiated.

Long-standing differences among the islanders have surfaced in often bitter campaigning and it is probable that at least two districts will reject the constitution. They are Palau in the western Carolines and the Marshall Islands far to the east.The four districts of the central Carolines are likely to approve but if only one joins Palau and the Marshalls in opposition, the entire arrangement would be scrapped.

The reasons for the internal split are cultural and economic, so the main issue has become not independence from the United States - almost everyone wants that - but a question of separation or unity within the islands.

Inhabitants of both the Marshalls and Palau tend to think they might fare better as separate entities and hope to negotiate their own status in association with the United States.

The Marshalls generate a large amount of tax revenue from Americans at the missile testing range on Kwajalein. If they merge with the other islands, the money would go into a common budget. If the Marshalls reject the federation and go it alone, they presumably would retain those revenues for themselves.

The Palauans, who are considered a cultural elite in Micronesia, also tend to feel they could negotiate a more advantageous deal separately. The United States is interested in leasing four large tracts for military purposes on Palau and Japanese interests are considering building a superport for oil tankers there. Either of these could generate enough income to move the population of 13,000 toward self-sufficiency.

If both the Marshalls and Palau opt out, the new federation would consist only of the least-developed islands in the Carolines, such as Yap and Truk, and would be almost totally dependent on U.S. economic aid.

The prospect is unsettling for the United States, which in nine years of acrimonious negotiations had tried to create a compact association of islands bound tightly to itself to serve American strategic interests in the Pacific. That goal was in conflict with the U.N. mandate that the islands be steered gradually toward self-determination and the United States is frequently accused of manipulating islanders for its own interest.

When the constitution was drafted in 1975, American officials at first declared that it was incompatible with the idea of free association with the United States. It amounted to complete independence, they contended. They also implied it would make Micronesians ineligible for U.S. aid, which amounts to about $130 million annually and is by far the biggest source of revenue.

In a major policy switch last April, however, the Carter administration accepted the constitution and pledged that, if it is adopted, aid would not be stopped unilaterally.

In a statement signed by American and Micronesian officials at Hilo, Hawaii, both sides agreed on a formula that continues U.S. assistance but also gives the United States strong defense rights in the territory.

The statement says that the Micronesians "will refrain from actions which the United States determines after appropriate consultations to be incompatible" with U.S. defense powers under the agreement.

The so-called "Hilo Statement" provides that in an agreement still to be drafted the United States - "will have full authority and responsibility for security and defense matters in or relating to Micronesia, including the establishment of necessary military facilities and the exercise of appropriate operating rights."

Just what the United States has in store militarily for Micronesia is not clear. It once planned a major installation on Tinian in the Marianas but that has been shelved. It is seeking options for land presumably to be used for bases in Palau.