By Marcus Walker and Nektaria Stamouli 

ATHENS--Greek leader Alexis Tsipras pursued both compromise and confrontation with his country's creditors on Wednesday while his government's rival factions fought over how, and whether, to keep Greece in the euro.

The embattled prime minister lambasted Greece's lenders--the German-led eurozone and the International Monetary Fund--in a televised speech after Europe rejected another last-ditch bailout proposal from Athens as too little, too late. He called on Greeks to vote "no" on Sunday in a referendum on creditors' demands, arguing that a popular rebuke to lenders would be "a decisive step for a better agreement" that "does not mean a rupture with Europe."

Yet fear and divisions are spreading inside Greece's government as the country teeters on the brink of bankruptcy, officials say. Moderate ministers and advisers who want the premier to accept Europe's bailout terms are increasingly panicking about the premier's erratic course, recognizing--despite Mr. Tsipras's claim on television--that a popular "no" vote is likely to lead to exit from the euro, while a "yes" would probably bring down the government.

Advocates of tough tactics toward the country's creditors, led by Finance Minister Yanis Varoufakis, are pushing the premier to hold his line, arguing that Europe will in the end offer Greece more-lenient financing terms rather than fracture the eurozone. Hard-line leftists in the ruling Syriza party are hoping for a "no" vote in the belief that a euro exit would be better than surrendering to Germany's and the IMF's market-oriented policy demands.

Conflicting opinion polls suggest Greek voters are equally divided. In a poll of 1,000 people published Wednesday and conducted for French bank BNP Paribas, 47.1% said they planned to vote "yes" or were likely to. An additional 43.2% said they would vote against accepting the bailout terms Greece's creditors are demanding, or leaning toward a "no" vote.

Another poll, also published Wednesday but for a left-wing Greek newspaper, put the "no" votes clearly ahead--but with a smaller lead since Monday when banks remained shut, spooking many Greeks. Of those surveyed after Greece imposed capital controls, 47% said they would vote "no," compared with 37% who backed a "yes" vote, according to pollster ProRata, which conducted the survey on Sunday through Tuesday.

Support for the "no" vote had been much higher, at 57%, among those polled by ProRata on Sunday, before the controls went into effect. Polls in recent years have shown that Greeks strongly support the euro but oppose further austerity demanded by creditors.

The behind-the-scenes arguments within Greece's government, elected only in January on a tricky platform of challenging Europe's demands for fiscal austerity while keeping Greece in the euro, are symptoms of the anxiety gripping the country ahead of Sunday's referendum.

The crisis has come to pervade every facet of Greek life since Mr. Tsipras called the vote over the weekend: Across the country, long lines of people wait at banks and supermarkets, families are glued to the TV news, and heated arguments break out on the streets about whom to blame for the mess.

A flood of deposit withdrawals forced Greece to shut its banks this week, casting a chill over the long-suffering economy. With Greece starting to default on its foreign debts and no European bailout program in place since Wednesday, many here fear the worst is yet to come.

"We've been in business for 41 years, and it's never been so bad," said Antonis Tartaras, owner of an eyewear boutique in downtown Athens. "God help us all."

Wednesday brought fresh twists in a Greek debt drama that has run for nearly six years, but which is now in a decisive phase. Mr. Tsipras pitched a compromise to Europe to prolong Greece's bailout, promising in a letter to European officials to accept most, but not all, of the fiscal belt-tightening measure that lenders were insisting upon in negotiations last week. Mr. Tsipras ended those talks in Brussels on Friday night by opting for a referendum on the list of economic measures that European authorities and the IMF were demanding.

On Wednesday, European officials dismissed the compromise bid from Athens as insufficient to revive negotiations. Eurozone finance ministers agreed on a conference call late Wednesday that there would be no further bailout talks with Greece until after its Sunday referendum.

The response to Mr. Tsipras's latest letter was particularly frosty in Berlin, where German Chancellor Angela Merkel and others said there is nothing to discuss with Mr. Tsipras until after Greece's referendum.

Ms. Merkel told Germany's parliament, the Bundestag, on Wednesday, that she remains willing to talk to Greece about financial aid after the vote, but only in exchange for tough economic reforms. She signaled that she is prepared to let Greece leave the euro if it doesn't accept the IMF-European overhauls.

"A good European is not one who seeks agreement at any price," Ms. Merkel said, in a swipe at some European Union officials' attempts to broker peace with Greece on more lenient terms.

Other German officials have said privately in recent days that it is becoming increasingly hard for Berlin to accept Mr. Tsipras as a reliable partner in a bailout deal, now that he has chosen to lead a referendum campaign against the creditors.

Mr. Tsipras's fiery rhetoric in his televised speech on Wednesday did nothing to dispel the mistrust. The leftist premier said that Greeks who vote "yes" to Europe's economic demands would be "accomplices" to austerity. He accused the rest of the eurozone of trying to blackmail Greece and scare its voters into accepting a bad deal. He also attacked the European Central Bank for curbing emergency liquidity for Greek banks, thus forcing their closure.

"The prevalence of extreme conservative circles led to the country's banks suffocating, with the aim of passing the blackmail from the government to each citizen individually," he said.

The Greek leader's oscillation between populist rhetoric and compromise offers has confused and angered European authorities all year, alienating many policy makers who were initially sympathetic to Syriza's core argument: that Greece's bailout program since 2010 has been unworkably harsh, leaving the country's economy and society gasping after an overdose of spending cuts and tax increases while denying it relief from unpayable debts.

Athens's erratic diplomacy reflects both the Syriza-led government's inexperience and its internal divisions, Greek officials concede.

Part of the government, led by Deputy Prime Minister Yannis Dragasakis, has long pressed Mr. Tsipras to sign a deal with creditors quickly, to protect a battered economy from further damage. Mr. Dragasakis suggested late Tuesday that Mr. Tsipras might want to cancel the referendum, or shift his support to a "yes" vote to creditors' terms, if it helped to secure a deal.

On Wednesday, hard-line Greek officials gained the upper hand in Athens again after Berlin dismissed Mr. Tsipras's letter. Mr. Varoufakis, the Greek finance chief, advised Mr. Tsipras to stick to his referendum and call for a "no" vote.

"The future demands a proud Greece within the eurozone and at the heart of Europe," Mr. Varoufakis wrote on his blog. "This future demands that Greeks say a big 'NO' on Sunday."

Greek officials who are critical of Mr. Varoufakis's strategy worry that Germany and other lenders would simply write Greece off after a "no" victory, forcing Athens to print its own money to reanimate its banks and economy.

Mr. Tsipras has hinted publicly that he would step down if Greeks vote "yes" to creditors' terms against his loud appeals. Some Greek officials say an interim government led by technocrats might succeed him and try to sign a new bailout deal, before giving way to elections in the fall. Other officials think Mr. Tsipras could survive a "yes" vote and stay in power for a few months until new elections.

Gabriele Steinhauser and Stelios Bouras contributed to this article.

Write to Gabriele Steinhauser at gabriele.steinhauser@wsj.com and Nektaria Stamouli at nektaria.stamouli@wsj.com