Every morning at the stroke of nine, in the western Ukrainian city of Chernivtsi, the entire town square comes to a standstill for a moment of silence to mourn the war dead.

Police officers block the streets. People hold their hands over their hearts. Languid, operatic music flows from a speaker positioned on a wrought iron balcony overlooking the cobblestone square. For a few minutes, as the sun beams down and flags snap in the wind, everyone and everything stops.

It’s a singular ritual, and the elaborateness is necessary, city leaders say, because standing here, in the middle of this beautiful town, where there’s not a sandbag, cracked window or soldier in sight, you can almost forget this country is at war.

Chernivtsi, tucked into the southwest corner of Ukraine, hundreds of miles from the front, has never been hit by a missile — and it’s not small, 300,000 people. There are few checkpoints or military vehicles or clumps of young men in camouflage crowding the coffee machine at the supermarket — like there always are in Ukraine’s cities in the east, center and south.

The peace here is remarkable, said Vasyl Zazuliak, a deputy mayor, “and we need to remember who we owe it to.”

But the city isn’t resting. It is trying to do its part to contribute. Behind the 19th-century facades and gorgeous avenues, where young people lost in their own thoughts stroll and savor the long summer nights, wartime activities are quietly unfolding.

People here and in villages nearby are building dune buggies for the front lines, providing homes to thousands of displaced Ukrainian civilians, shipping supplies to the east and using their proximity to Poland and Romania to bring in more.

Chernivtsi and much of western Ukraine have, in effect, become the back office of the war.

“We don’t have troops marching in our streets. We don’t have missiles flying over our heads,” said Lily Bortych, a farmer, the chairwoman of a large charity organization and a member of the Chernivtsi regional council. “But we understand the responsibility of helping out.”

She listed the things her charitable organization does: imports medicines; distributes millions of pounds of humanitarian aid; trains hundreds of emergency counselors; and provides vegetable seeds to women in recently liberated areas so they can begin once again to grow some of their own food.

“War is won not only by people on the front lines,” she explained, “but also by people in the rear.”

There’s an unmarked line a couple hundred miles west of Kyiv where things begin to look different and feel different. This area has its own history. It was ruled by the Austro-Hungarian empire until World War I. Its buildings and urban layout are less Soviet era and more continental Europe — colorful, ornate and delicate.

Since this war began, western Ukraine has differed in another respect as well: It has become a refuge for millions of Ukrainians fleeing the bloodshed from other areas, a place where people can feel safe and still be in Ukraine.

“I don’t feel the war at all,” said Volodymyr Totskyy, an electrical mechanic, who fled an occupied area in Zaporizhzhia with his wife and child.

Not all of western Ukraine has been spared. Lviv, the biggest city and home to important factories and military institutions, has been hit several times, including a strike in July that killed 10.

Chernivtsi ranks at the bottom of the list for air raid alarms. It feels relaxed. Each night, the town’s prettiest strolling spot, Olhy Kobylyanskoi Street, named after a feminist writer, fills with families, couples and groups of teenagers roaming around, just as in cities all over the world.

“We’re lucky to live here,” said Yurii Ivanchuk, a prosecutor. While other Ukrainian cities have army surplus stores along the main thoroughfare, in Chernivtsi it’s chocolatiers and candy shops, one of which Mr. Ivanchuk was visiting with his wife and son.

“Our small region isn’t producing anything for the military,” he said, as his son dug into a bag of candy. “Apparently, the Russians aren’t interested in us.”

Fewer than 30 miles from Romania, Chernivtsi has been a trading hub for centuries, attracting a multilingual population and a large Jewish community. Most of the Jews were wiped out in World War II, but their ancestors remain here, entombed in a seemingly endless, weed-choked graveyard. It is filled with crooked headstones carved in three languages — Russian, German and Hebrew — looking as if they are about to topple over.

Most of the city, though, feels lively and well kept. Splendid buildings in all hues, designed with arched windows and mysterious cupolas, line the avenues. UNESCO recognizes Chernivtsi’s golden-brick university as a World Heritage Site, calling it “an outstanding example of 19th-century historicist architecture.” Locals call it “Ukrainian Hogwarts.”

The university attracts students from thousands of miles away, and the other night, Labil Shaikh, a medical student from India, took a leisurely walk through the center of the city.

“My parents call me all the time and ask: ‘Are you OK? Are you in danger?’” he said. “So I come out to this promenade and take some video and send it home and they chill out.”

“Annoying,” he added.

Looking up at the intricately made wrought iron balconies, or down at the glossy cobblestone streets, you might for a moment think you were in Vienna or Paris.

But many Ukrainians say that even the safest parts of their country are not untouched and that the war is like a spider’s web, connecting every Ukrainian. In a recent survey of several thousand Ukrainians, 78 percent said that they had close relatives or friends killed or wounded in the war.

Chernivtsi has lost a lot of people, too. Sometimes it buries two young soldiers a day.

The moment of silence each morning is meant to mark the sacrifice of all of Ukraine’s troops. It was another savvy move by the country’s president, Volodymyr Zelensky, a former actor who seems to have a knack for public gestures.

Mr. Zelensky signed a decree last year ordering public institutions to observe a minute of silence every day at 9 a.m. to honor the war dead. Chernivtsi took it a little further.

First, city officials began playing a 19th-century anthem, “A Prayer for Ukraine,” in the town square. Then, when some people kept going about their business, “spoiling the mood,” said Mr. Zazuliak, the deputy mayor, the city instructed the police to cordon off the streets for the three minutes or so that the ceremony lasts.

“Yeah, I’m in a bit of a rush,” said Serhii Kovalchuk, a taxi driver whose arm was hanging out the window as the ceremony began, leaving him stuck behind a police barricade and staring at a green light. He cut off his engine.

“I just got another job,” he said, glancing at his phone. “But they can wait.”

As the music played, one couple in their 30s stood especially rigid. A tear slid down the woman’s cheek.

Afterward, when asked what she was thinking about, Iryna Kachynskyya, who comes from a town 300 miles away, said: “My brother.”

She paused and then said: “He was killed in the east.”

She and her family were taking a road trip across western Ukraine. She had read about Chernivtsi’s ritual on Facebook and felt it was important to see it.

“It’s a beautiful city,” she said. “A mini Paris.”

Before leaving, she took one last look around the square.

“I’m glad we came,” she said.

Oleksandra Mykolyshyn contributed reporting from Chernivtsi.