MOSCOW—Russia is planning triumphant ceremonies and public rallies as President Vladimir Putin prepares to formally annex a broad, additional swath of neighboring Ukraine in the coming days.

The celebrations are set to echo the pomp and circumstance that accompanied Russia’s seizure of Ukraine’s Crimean Peninsula eight years ago, an event that Mr. Putin marked in the imperial grandeur of the Kremlin’s gilded St. George’s Hall.

Russia’s capture of Crimea was quick and nearly bloodless and vaulted Mr. Putin to new heights of popularity at home.

Today, the new annexations, as well as a series of unpopular moves putting the country on war footing, raise the risk of overreach as he grasps for a breakthrough in the Ukraine war, say political analysts.

The annexations will up the ante in a war that Russia has been losing, and leaves Mr. Putin dangerously short of exit options, the analysts say.

In annexing the occupied territories, Russia will declare sovereignty over provinces that it only partially controls and where Ukrainian troops are advancing. If Russia fails to reverse the tide with 300,000 hastily trained troops that Mr. Putin mobilized last week, he faces the prospect of a wider draft of military-aged men that would be deeply unpopular inside the country.

Nationalist politicians are pressing Mr. Putin to declare martial law that would put the economy on a wartime footing, close Russia’s borders to stop the tens of thousands of draft-age men who have fled the country since last week and possibly impose some restrictions on foreigners.

Mr. Putin will participate in a Kremlin ceremony Friday in which four regions of Ukraine will formally be accepted into Russia, signing treaties in the Kremlin’s St. George’s Hall. Moscow has closed off roads around the Kremlin, in anticipation of a concert on Red Square and rally that will continue into the evening.

Next week the upper house of Russia’s parliament is expected to rubber stamp the annexation of the occupied Ukrainian territories. The festivities, while harking back to spring of eight years ago, precede what promises to be a bloody and difficult winter. Unlike the quick seizure of Crimea in 2014, the war in Ukraine since February has cost Moscow at least 80,000 wounded or killed, according to Western estimates.

Those casualties are likely to grow, as Russia tries to stanch the Ukrainian advance and claw back territory it lost before Ukrainian offensives in recent weeks.

The mobilization has already exposed festering class resentments inside Russia and triggered protests in heavily working class and minority regions, in addition to Moscow and St. Petersburg. More than 100,000 people have left the country since Mr. Putin issued the order last week. They join several hundred thousand others who left Russia in the months after the February invasion.

Russian conscripts said goodbye to relatives in Moscow.

Photo: yuri kochetkov/Shutterstock

Top Russian officials have expressed no regrets about the exodus. The head of Russia’s election commission, Ella Pamfilova, likened departees earlier this week to rats deserting a ship. Without them, “the ship will only be easier,” she said, according to the commission’s Telegram channel.

The head of Russia’s State Duma, Vyacheslav Volodin, called them cowards “who have not yet smelled gunpowder but have already hidden under the bed.” Cars, abandoned at the border by men who decided to flee on foot, should be seized and donated to Russian soldiers fighting in Ukraine, he said.

Andrei Kolesnikov, a senior fellow with the Carnegie Endowment for International Peace, said that coming festivities around the annexation might help add to a veneer of calm. But below the surface are deep worries about Mr. Putin’s direction, he says.

“There is no joy, as there was, because back then it was an act of pure patriotic delight—the capture of a culturally and historically important land, Crimea, without a single shot being fired,” he said. “But here it is a bloodbath. Putin is forcing Russian men to share responsibility for the war with him.”

Polls suggested that the mobilization would be deeply unpopular with Russians, but Mr. Putin had little choice given the large losses on the battlefield. State-controlled television, which earlier this month announced it was dialing back its coverage of the war, has resumed broadcasting stories of triumph on the battlefield and featuring footage of recruitment stations where young men are volunteering.

A recent rally in St. Petersburg, Russia, in support of annexation referendums in Russian-held regions of Ukraine.

Photo: olga maltseva/Agence France-Presse/Getty Images

Russians who crossed the border into Georgia recently. More than 100,000 people have left Russia since a mobilization order last week.

Photo: Zurab Tsertsvadze/Associated Press

The mobilization has won plaudits from Russia’s hard-line nationalists. They want Mr. Putin to take the war effort further, saying a broad mobilization would heal Russia’s divisions.

“If there is a war, then everyone participates in the war—billionaires, the poor, residents of small towns, urbanites, scientists, the homeless, the president and his family and my own family,” wrote Alexander Prokhanov, editor of the nationalist newspaper Zavtra, last week.

Mr. Prokhanov didn’t respond to requests for comment.

Mr. Prokhanov, whose work has long bemoaned the fall of the Soviet Union and, after the seizure of Crimea, praised the political order of North Korea, said he looked forward to mobilization of “the entire country, the restoration of deep justice through this mobilization.”

Top officials in parliament have lately called for restrictions on borders, only to be contradicted by Kremlin officials.

In his address last week, Mr. Putin described the call-up of troops as a partial mobilization that will activate only veterans and reservists. But fears have quickly spread of a general draft and a broader mobilization that would affect the economy too, and require by law businesses to help register their staff if qualified for military service and also assist in supplying the military.

Police officers detained a man in Moscow following calls to protest the recent mobilization order in Russia.

Photo: Agence France-Presse/Getty Image

Pro-Kremlin foreign policy voices in Russia have rallied behind the mobilization. In an interview published this week, Sergey Karaganov, head of Russia’s Council on Foreign and Defense Policy, said Russia is fighting for its survival in Ukraine.

Mr. Putin hinted that Russia could resort to nuclear strikes to defend itself from what he describes as aggression on the part of the U.S. and Ukraine’s other allies. In the interview, Mr. Karaganov suggested that the U.S. wouldn’t retaliate if Russia were to strike a minor city in Poland.

“They will retaliate with a nuclear strike against Russia’s limited use of nuclear weapons only if there is a lunatic in the White House,” Mr. Karaganov told Russia’s Profile magazine. “Or a person who hates America and is ready to sacrifice, say, Boston for the sake of Poznan.”

SHARE YOUR THOUGHTS

What do you think Vladimir Putin might do next? Join the conversation below.

Officials from the Biden administration have said that it has warned Russia that it would face “catastrophic consequences” if it uses nuclear weapons in Ukraine.

Pollsters say most Russians have shown little enthusiasm for fighting in Ukraine. However, public protests remain muted, while the Kremlin quickly suppressed demonstrations that emerged over the last week against the mobilizations.

Civic groups that would connect disgruntled servicemen with one another or help Russians avoid conscription have been abolished or driven underground by Mr. Putin’s vast security establishment. Those groups could coalesce, however, as the war drags on.

Mr. Putin, who has long argued that Ukraine’s borders were an accident of Soviet planning and is historically an integral part of Russia, published a lengthy treatise last year that amounted to a pretext for invading, falsely saying that Ukraine never had been an independent state and lacked its own culture or language.

While Mr. Putin has repeated those arguments on television and in interviews since then, it isn’t clear that many Russians or even Kremlin elites share his view, said Thomas Graham, a distinguished fellow at the Council on Foreign Relations.

Mr. Graham said the lack of enthusiasm will sap the war effort. “If you look at the history, the Russians are tenacious about defending their own territory,” Mr. Graham said. “It’s a little bit different fighting outside—and dying for what? A lot of Russians don’t care about the historic idea that Ukraine is part of Russia.”

Reservists in Sevastopol, on the Crimean Peninsula, which Russia seized in 2014.

Photo: stringer/Agence France-Presse/Getty Images

Write to Alan Cullison at alan.cullison@wsj.com