Feuding between priests and potentates dates almost to the founding 12 centuries ago of this temple-studded city, the imperial capital of Japan in feudal times and the country's prime tourist attraction today.

In the year 1570, tensions reached the point that warlord Oda Nobunaga put the torch to hundreds of Buddhist monasteries on Hiei mountain outside the city to show the monks who was in charge.

Now, the old rivalry has flared again. Priests at 12 of Kyoto's best-known temples this month angrily closed the gates rather than collect taxes from visitors to fund a city preservation program. The priests say the tax is unconstitutional.

Entrance to Kiyomizu Temple, whose soaring wooden main hall stands without benefit of a single nail, is blocked by a modern steel fence. "Until Kyoto city respects the August 8 agreement, we will remain closed," declares a large placard. It refers to a plan that was supposed to settle the dispute.

"There is no end in sight," laments Dr. Takashi Ohmiya, a sake company chairman who sat on a special three-member "wise men's" commission set up to mediate. The group dissolved itself in failure in November.

Like many disputes in Japan, a society where one person's opinion tends to match the next's, this one is grounded in form as much as substance -- the temples are willing to pay, but not to call it a tax. Still, both sides have dug in their heels. City officials say it is a question of rule of law; for priests, it is a battle to defend the faith.

Japan tolerates all religions but few Japanese give serious thought to any of them. Though about 90 million of Japan's 120 million people are officially classified as Buddhists, they darken temple doors mainly during funerals or school outings to historic sites such as Kyoto.

Priests command respect but almost no one can fathom the scriptures they read or ceremonies they conduct, a fact mercilessly lampooned in a recent hit Japanese film, "The Funeral," the story of an ordinary family attending to a member's cremation.

With close to 1,700 temples, Kyoto is headquarters for Japanese Buddhism (there are also about 270 shrines of the separate Shinto faith). In the morning, monks are seen engaging in ritual begging for food along the streets, a rare sight in other major Japanese cities.

In former days, the city's priests fielded private armies. The clout they are bringing to bear today, however, is economic. Their temples are among the greatest surviving examples of grand wooden architecture of past ages and help draw close to 40 million tourists a year to Kyoto.

The tourist tax -- 50 yen, about 25 cents, for adults and 30 yen for children -- is targeted only at 37 temples, shrines and a castle, which are the major attractions of the city.

With little industry, the city depends on tourism to keep thousands of people in work. The priests are gambling that the city will give in as tourism trails off and hotels, souvenir shops and restaurants feel the squeeze. December, however, is off-season and so far the impact has been manageable.

The Kyoto Buddhist Association, which is leading the strike, contends the tax violates separation of church and state contained in the constitution that U.S. military occupation authorities imposed after World War II. It also violates a former mayor's pledge, the association says.

The tax could set a precedent for others on donations of ordinary members at small temples, argues Gencho Komatsu, a priest who is association director general. "Temples elsewhere in Japan may feel this is not their concern," he says. "But when the government starts taxing them too, they will all stand up together."

Association manager Kojo Nagasawa cites more immediate concerns as well: "Our visitors come to acquire holy and tranquil feelings," he says. "Temples exist to serve others. If we ask our visitors instead to pay a tax, it's an act of suicide for us."

City officials, however, seem to see the temples more as antiquarian Disneylands than places of worship. Many temples have no congregations. Despite claims the tax would inhibit visits, most temples already charge at the door. Three hundred yen, about $1.50, is common for adults -- six times the tax.

Ticket income is supplemented by aid from the central government, which has designated the big temples as national treasures. Some have become quite prosperous. Senior priests work in private offices that have thick carpets and color television sets. Except for the robes and Buddha images, the scene is hardly distinguishable from corporate Japan.

The temples' land and buildings, as in the United States, pay no property taxes. But twice in the past, Kyoto city has managed to augment its accounts by taxing visitors, despite grumbles from the abbots. When the last tax expired in 1964, the mayor promised never to levy a tax again.

But several years ago, with city finances in the red and the 1,200th anniversary of Kyoto's founding coming up, officials began casting about for funds for roads, parking and other tourist facilities and reconstruction work at smaller temples. Ruling out parking and restaurant taxes on technical grounds, they settled on a new visitors' tax. The old mayor's pledge, they said, was only a private one.

The law was passed by the city council in 1983. Implementation was delayed while the courts dealt with legal challenges. The tax, meanwhile, was endorsed by the central government, which is battling to control deficits in its own budget and welcomes local initiatives for funding.

Over the summer, temples began striking even as a consensus to cooperate was emerging among them. "Japan is a country ruled by law," says priest Eishin Taki, secretary general of the Sanjusangen-do Temple, which is paying the tax. "We cannot violate the law."

On Aug. 8, with the mediation panel's assistance, the two sides reached written agreement under which temples would make "contributions" to the city. The city, in turn, would accept them as payment of the tax. Everyone was happy and the temples reopened.

But subsequently, the plan was ruled illegal. Tempers flared anew as the city insisted the temples be officially designated as tax collection agents. Officials asked to see temples' records of visitors. The priests refused. The city sent officials to the gates to count visitors. Monks angrily told them to leave. In early December, temples began closing again.

Monks tend to see city officials as petty bureaucrats interfering in religious affairs. Officials, on the other hand, suggest the men in robes want to be treated as divine and hint that their books are not in order. They cite surveys showing that many religious organizations in Japan maintain improper tax records.

Caught in the middle are merchants who rely on the tourist trade. "Our representatives several times visited the temple to plead for reasonable behavior," says Noboru Chujo, 71, who owns a souvenir shop outside Kiyomizu Temple and has seen sales drop 80 percent this month. "They told us, 'We understand your position, but please endure it for awhile.' "

Twenty-five of the designated sites are now paying the tax. But the 12 holdouts are among the biggest attractions the city offers. Many foreign and Japanese tourists, have arrived on long-planned, costly trips to find disappointment.

One of them was Steven Brook, a 29-year-old electrical engineer from San Diego who has seen plenty of labor unrest since beginning a trip around the world in August. "I've run into air traffic controllers' strikes, postal strikes, garbage strikes and bus strikes," he said in Kyoto, his last stop. "But I've never seen a temple strike."