President Daniel Ortega, in a somber speech to a rally in the northwestern city of Esteli marking the seventh anniversary of the rise to power of the leftist Sandinista Front, warned his countrymen today to expect "great difficulties" in their daily lives as a result of increased U.S. backing for rebel forces.

In addition, Ortega told neighboring Central American governments that this is a "time of definition," in which they must either side with Nicaragua in regional peace talks or join U.S.-backed efforts to overthrow the Sandinistas.

The rally in Esteli, which was attended by a relatively sparse gathering of 10,000 Sandinista sympathizers, took place amid heavy security. Esteli is a provincial capital, 25 miles south of Honduras, where the anti-Sandinista rebels, known as counterrevolutionaries, or contras, are based.

The city was cordoned off by military checkpoints. Soviet-made combat helicopters circled overhead.

Charging that the United States is waging war on Nicaragua's economy, Ortega said, "We can tell you now that a difficult economic struggle will be with us as long as the United States attacks us."

He told Nicaraguans working in services and trade to expect increasingly severe shortages because limited food supplies will be channeled to soldiers and workers in basic production. He defended a crackdown on political and religious dissent adopted after the U.S. House of Representatives voted last month to give $100 million in military and nonlethal aid to the contras.

"Our objective is not to radicalize our revolution but to preserve its pluralism," he asserted.

"Within the framework of our institutions everyone can say what they want," Ortega added. "But anyone who steps outside that framework to become an ally of those who are attacking us will be recognized as a traitor."

The president, wearing a plain olive-green uniform, said more than 31,000 Nicaraguans on both sides have been killed, wounded or kidnaped in nearly five years of war. The country's population is 3.7 million.

Ortega's roster of the dead included 103 schoolteachers and five doctors.

Nicaragua will give the United States until July 27, Ortega also said, to declare whether it will respect a decision favorable to Nicaragua issued last month by the World Court in The Hague. After that Nicaragua will take the issue to the U.N. Security Council, he said. The United States has said it would not accept the court's jurisdiction in the case, which stemmed from the CIA's 1984 mining of Nicaraguan ports.

For many Nicaraguans, including those who have become disillusioned with Sandinista policies, July 19 provides a nostalgic return to the idealistic days when there was near unanimity in the battle to oust Anastasio Somoza.

But today, Nicaraguans from other cities could not attend the rally unless they traveled under the auspices of the ruling Sandinista National Liberation Front.

There were few high-level diplomatic delegations at the rally. Libyan Foreign Minister Kamal Mansour and Czechoslovak Vice President Miroslav Toman were among the most important guests.

Special correspondent Nancy Nusser contributed to this report from Esteli.