The House yesterday narrowly voted to begin building MX missiles at a cost of $2.6 billion next year, despite the fact that all sides admit that no one knows where to put them.

A coalition of liberals and fiscal conservatives came within three votes of passing an amendment that would have delayed the MX by striking almost half the funds, $1.14 billion to build the first nine missiles, but were defeated, 212 to 209, after a last-minute push by Reagan administration lobbyists.

President Reagan has said that cutting the funds would weaken the U.S. position in negotiating arms control with the Soviets.

In another key vote on the defense authorization bill, the administration and the House Armed Services Committee squashed an attempt by the Boeing Co. to substitute used 747 commercial planes for the proposed purchase of Lockheed C5 cargo planes to transport helicopters and other large equipment in military emergencies.

Proponents of the MX funding delay, led by Reps. Nicholas Mavroules (D-Mass.) and Beverly B. Byron (D-Md.), thought they had enough votes, but were outmaneuvered at the last minute by Rep. Samuel S. Stratton (D-N.Y.).

Stratton won a substitute amendment that included funding for all the missiles but put a hold on $260 million in basing and deployment funds until the president decides on a basing system. Withholding the deployment funds gave enough members a rationale for voting for the system to enable Stratton's amendment to carry.

The proposed land-based missile system has been plagued with political and technical problems since President Carter in 1979 recommended that 200 MX missiles be placed on transport vehicles and shuttled between 4,600 underground shelters in an elaborate "shell game" to confuse Soviet targeteers.

The Reagan administration rejected this plan, and has been studying several alternatives. At the moment, the leading candidate is called "Dense Pack," which calls for placing 100 MX missiles closely bunched together at a single location.

The idea is that the explosions from the first Soviet missiles aimed at the MX silos would either destroy or blow off course the following Soviet missiles meant to wipe out the MX force.

In this manner, a number of MX missiles in the "Dense Pack" theoretically would survive, although many critics believe the concept has serious flaws.

The Senate dropped all MX funding from its weapons authorization bill in May, because of uncertainty as to where and how the missiles would be based. After the House passes its defense authorization bill it goes to conference, where a fierce administration lobbying effort is anticipated.

If completed, the 100-missile system, designed to attack Soviet weapons silos with unprecedented speed and accuracy, would cost more than $25 billion. Opponents, however, argue that the missiles are virtually worthless if they are vulnerable to Soviet attack, an issue which will remain unresolved until a suitable basing system is designed.

"If we we build this missile, where do we put it, in a warehouse?" Mavroules asked. "From day one, there have been 35 different basing modes. Isn't it time we said to the administration, 'Enough is enough?' As long as we continue to fund it, they'll spend the money and not come up with any answers."

Stratton, however, argued that Reagan has promised to decide on a basing system by December.

Even if MX production begins immediately, the missiles would not be deployed until 1986, he said, adding that opponents should have "confidence in the scientific and technological genius of the Americans who have sent man to the moon, that by 1986 we will have developed a basing mode."

While the MX debate cut across ideological and party lines, the battle over the cargo jet, which sparked five hours of spirited debate, was more of a parochial matter.

Leading the charge for Boeing was the congressman from Boeing's district, Democrat Norman D. Dicks, and his fellow Washingtonians. Heading the Lockheed forces was the Georgia delegation, protectors of Lockheed's Marrietta plant.

Large cargo planes are an important element of the Rapid Deployment Force because of the need to transport helicopters, tanks and other outsized equipment to distant parts of the globe on short notice.

Dicks' amendment to cut funds for the C5B cargo planes by $450 million and to spend $410 million for commercially available cargo aircraft failed, 289 to 127. Earlier, a proposal by Rep. Robert E. Badham (R-Calif.) to delete all funds for cargo aircraft was defeated, 344 to 74.

The confrontation between the two aircraft companies involved a massive lobbying campaign and full-page ads in major newspapers extolling the virtues of each plane. In May the Senate authorized purchase of 747s, accepting the argument that they are available sooner and at less cost than Lockheed's C5Bs.

Lockheed proponents pointed out that their planes could carry larger equipment and land on dirt fields, whereas Boeing's needs prepared airfields. Trucks and tanks could drive into the Lockheed planes, but would have to be lifted 16 feet into the 747s.

While acknowledging the history of technical problems that plagued the C5, members of the Armed Services Committee, from conservative William L. Dickinson (R-Ala.) to liberal Les Aspin (D-Wis.), argued that it was the most practical solution, given the drawbacks of the Boeing planes and the long lead time involved in developing an entirely new plane.

Lockheed proponents "will say anything to sell their proposal on Capitol Hill," Dicks charged, adding that the planes from Boeing, which has suffered severe economic difficulties, are available "at a bargain basement price."

On the Stratton amendment the entire Virginia delegation voted "aye." All Maryland Democrats voted "nay," while Maryland Republican Marjorie S. Holt voted in favor of the amendment.

On the Dicks amendment Maryland Democrat Steny Hoyer voted yes, while his fellow Democrat, Michael D. Barnes, and Holt voted no. Virginia Republican Frank R. Wolf voted yes, while Stanford E. Parris voted no.