Mexico's debt crisis eased today when major banks agreed to forgo repayment of $10 billion in loans that come due in the next 90 days and to start lending the country an additional $500 million to $1 billion within a few days.

Mexico promised that it would continue to meet interest payments on foreign loans, and the banks agreed to renew the loans that come due during the next 90 days, freeing Mexico from having to make payments on principal during that period.

Today's agreement was the latest in a series of emergency steps to inject foreign exchange reserves into Mexico in an effort to overcome a critical cash shortage that has threatened its ability to make payments on more than $75 billion in debt to foreign banks and other lenders.

The 90-day grace period is intended to give Mexican authorities time to arrange a $4 billion, three-year loan from the International Monetary Fund and secure up to $800 million from a separate IMF fund.

Deputy Treasury Secretary R.T. McNamar said in Washington today that Mexican agreement with the IMF was a "keystone" of a broader rescue package being assembled by banks and governments under U.S. leadership. Without the IMF agreement the other parts may not fall into place, he said.

Officials from 115 banks in the United States, Canada, Europe and Japan met privately with Mexican Finance Minister Jesus Silva Herzog at the Federal Reserve Bank of New York this morning.

Most bankers trooped out of the meeting shortly after noon today and said "no comment" to waiting reporters. But Jean de Marce, senior vice president of Banque Nationale de Paris, said he was pleased with the agreement and that bankers were willing to help Mexico further so the country can overcome its "cash crisis." He said the "situation is not so bad . . . . Mexico is a rich country with many resources."

"There was little doubt we were going to do what they asked, especially with the governments also putting up funds," said a major official of a U.S. bank.

Eighteen months ago, Mexico was awash in oil profits and was a favorite customer of the world's banks. But a decline in oil demand and prices, coupled with a fall-off in demand for the country's other major exports (such as coffee, silver and copper) and reduced earnings from tourism plunged debt-laden Mexico into a serious cash shortage.

Since the Mexicans closed their foreign exchange markets a week ago and went to the international community for cash, the United States and other countries have moved swiftly to put together an emergency rescue package.

The United States agreed last weekend to give $1 billion in advance payments for Mexican oil to be stored in the strategic petroleum reserve and made the money available last Monday, McNamar told reporters.

It is working with other industrialized nations to supply a short-term loan of $1.5 billion through the multi-nation Bank for International Settlements in Switzerland. The loan should be ready in the next few days. And the United States also agreed to guarantee $1 billion of cheap loans in fiscal 1983 for the purchase of American agricultural products via the Commodity Credit Corp.

Mexico has exhausted a $700 million loan from the U.S. Federal Reserve, available under the so-called swap arrangements central banks maintain with each other. McNamar said that this money ran out two or three weeks ago.

All these steps are bandages to supply Mexico with emergency cash to buy imports and pay interest on its debts until it can complete negotiations with the IMF. Of this, about $4 billion will be subject to Mexican agreement to IMF policy conditions.

Mexico also has requested up to $800 million from a special fund set up in the wake of the oil price rise to help poor nations with emergency balance of payments problems Although money from this fund has never gone to an oil-exporting nation, the IMF is likely to agree to allow Mexico to draw from it, sources said today.

An IMF team is in Mexico City negotiating the terms of this agreement, which likely would include promises from Mexico to cut back public spending, reduce subsidies to essential goods, and move toward reinstating a free exchange market.

Herzog, the Mexican finance minister, has already discussed the outlines of an agreement with IMF Managing Director Jacques de Larosiere, sources said.

Herzog told reporters today that after negotiations are concluded with the IMF, Mexico will turn to its bankers again to restructure the private debt the country has outstanding now and to borrow more. All told Mexico owes private banks and foreign governments about $75 billion, Herzog said.

Of this, about $22 billion is owed to U.S. banks, McNamar said. This is 10 times as much money as U.S. banks had at stake in Poland. It is partly the size of the American involvement that has encouraged the United States to move so swiftly to help Mexico, an international official said.

A steering committee of 14 officials of the biggest banks involved will continue to negotiate with Mexico and those banks met this afternoon at Citibank, one of the four largest U.S. lenders to Mexico.

Bankers and U.S. officials think that Mexico will have little trouble satisfying IMF requirements for a major loan. The Mexican government already has taken many of the types of austerity measures the IMF usually demands, a private banker noted.

Perhaps just as important, the speed with which the United States and other major countries have moved to put together a rescue package suggests that they are very anxious for the IMF to reach agreement with the Mexicans, sources said.