CAIRO — Clutching a decades-old black-and-white photo, Doris Wolanski directed a vehicle through Cairo's chaotic traffic, her gaze trained on the street corners, in search of rue du Metro.
The photo showed an 8-year-old girl and her mother on a balcony overlooking a wide, deserted boulevard. The girl was Mrs. Wolanski, now 71; the apartment was her Jewish family's home until they were expelled from Egypt in 1956, during the Suez crisis. Now she was trying to find it again.
The address wasn't much help — rue du Metro had been renamed — but she hoped that details on the photo might lead her home. Spotting a familiar landmark, she filled with anxious anticipation.
"My stomach is churning, it really is," she said. "I'm back to that little girl of 8 with my uniform, two pom-poms and a hat. It's a very strange feeling."
Mrs. Wolanski's mission was part of a much larger homecoming for Egypt's Jewish community, which at its peak numbered 80,000 and is now racing toward extinction.
Last weekend, 180 Jews from Europe, Israel and the United States traveled to the city of Alexandria on Egypt's Mediterranean coast to attend religious ceremonies at a historic synagogue that was rescued from ruin. It was the largest such gathering of Jews in Egypt since they were pressured to leave during the Arab-Israeli wars of the 1950s and 1960s.
Egypt's government paid for the $4 million synagogue renovation — part of a longstanding drive to rescue the country's crumbling Jewish heritage which President Abdel Fattah el-Sisi has stepped up.
Last year, Mr. el-Sisi ordered the renovation of a badly dilapidated Jewish cemetery which is one of the oldest in the world.
And he supported a scholarship project, run with the help of an Israeli scholar, that uncovered a rare, 1,000-year-old Hebrew Bible.
But Mr. el-Sisi's embrace of Egyptian Jews is also awkward and laced with contradictions. The visit of 180 Jews took place under a news media blackout, with no coverage in Egyptian outlets, and amid iron-tight security by Egyptian officials who at times outnumbered their visitors.
Although Mr. el-Sisi paints himself as a moderate, he has done little to counteract anti-Semitism in Egyptian society, where Jews are often conflated with Israel, and where many young Egyptians know little of their country's Jewish past — and how it ended.
"I'm full of questions," said Philippe Ismalun, who fled Egypt after his father was arrested during the 1967 Middle East war. "After so many years of Jews being told that Egypt is not their country, not their home, it was puzzling to see the government spend so much money and effort on renovating the synagogue."
In part, the answer is politics.
Perhaps 16 Egyptian Jews remain in Egypt — six in Cairo and another 10 in Alexandria, mostly in their 70s and 80s, according to community leaders in both cities. The government says it is rescuing their synagogues and cemeteries so Jewish heritage can take its rightful place alongside Egypt's Pharaonic, Coptic and Islamic civilizations.
"It's a message for Egyptians that we lived in a unique diversity — Jews, Christians, everyone — for millenniums," Khaled El-Anany, Egypt's minister for antiquities and tourism, said in an interview.
For Mr. el-Sisi, though, the good works also cement his foreign alliances. In recent years, Egypt has quietly allied with Israel to carry out secret airstrikesagainst the Islamic State in Sinai. Mr. el-Sisi's officialswere mutedin their criticism of President Trump's contentious plan to resolve the Israeli- Palestinian conflict.
Since Mr. Trump came to power in 2016, Mr. el-Sisi has hosted at least 10 delegations of American Jewish leaders at his presidential palace, apparently viewing them as a vehicle to leverage influence in Washington.
Squatters had encroached on the ninth-century cemetery, building houses and stealing its marble tombstones. Sewage pooled in corners, goats roamed between graves and garbage was piled high in places.
Local criminals used the cemetery as a place to deal drugs or burn the rubber coating from stolen electrical cables, said Magda Haroun, the head of Cairo's half-dozen strong Jewish community.
"It was in a terrible shape," said Ms. Haroun, 67, whose sister's grave lies beneath a squatter's house.
A cleanup started within hours of Mr. el-Sisi's meeting with the American group, she said. It has been continued by A Drop of Milk — an old Jewish welfare organization now dedicated to rescuing Jewish heritage, and composed mostly of Christian and Muslim volunteers.
"We've removed tons and tons of rubbish," she said. "But there's much more to be done."
For many of the Jews who returned to Alexandria last weekend, the Shabbat service at the renovated Eliyahu Hanavi synagogue, an imposing neo-Classical structure that officially reopened in January, was an emotional moment.
A cavernous ark holds dozens of Torah scrolls collected from Alexandria's other synagogues that have been sold to developers. Heavy wooden pews gleam with brass plaques bearing the names of Jewish families since scattered across the world.
Mr. Ismalun, who lives in Switzerland, brought along the kipa he wore as a child for his bar mitzvah in the same synagogue.
"It was very moving," he said.
Yet many could not fail to notice that the news media had been barred from the event, and that not a single Egyptian government official had come along. Many said they felt isolated, and it raised a broader question about whether Mr. el-Sisi will allow ordinary Egyptians access to the synagogue that his government has so lavishly restored.
"The Egyptian attitude is between ambivalent and schizophrenic," said Rabbi Andrew Baker of the American Jewish Committee, who noted that he also attended the reopening of a Cairo synagogue 10 years ago, under President Hosni Mubarak, which took place insimilarly veiled conditions.
"The Egyptians appreciate that people have a positive view of this from abroad," Rabbi Baker added. "But now that you have this beautiful synagogue, it's fair to ask what purpose it will serve in the future."
Egypt's unresolved relationship with Israel is undoubtedly a factor. Despite a 1979 peace treaty, the two countries have not normalized relations, and public debate about the subject remains taboo in Cairo. In 2016, an Egyptian lawmakerwas expelledfrom Parliament for inviting the Israeli ambassador to his home for dinner.
Copies of "The Protocols of the Elders of Zion," an anti-Semitic tract, are sold openly by street vendors in Cairo. After a spate of anti-Sisi protests in September, documentscirculated on social mediathat purported to prove an old conspiracy theory that Mr. el-Sisi's mother is secretly Jewish.
At the same time, there are signs of changing attitudes.
Documentaries about the last Egyptian Jews have received a warm reception from young Egyptians eager to know more. And the government authorized an Israeli scholar, Prof. Yoram Meital of Ben Gurion University, to help A Drop of Milk catalog thousands of Jewish scrolls and other relics in Cairo's shuttered synagogues.
Two years ago, that led them to a goatskin parchment in the back of a closet — a handwritten document, dating from 1028, that covers the third part of the Hebrew Bible and is among the oldest copies of the Bible ever found.
"Many people think the final chapter on the Jewish community of Egypt has been written," Mr. Meital said in an interview. "I believe the opposite is true — that its heritage has a future that is beginning now."
Mr. el-Sisi's outreach has its limits. Jewish leaders want access to a vast register of community records, dating back to 1830 and counting tens of thousands of pages, that catalog births, marriages, deaths and bar mitzvahs.
But Egyptian officials have sequestered the register inside the national archives and, despite a promise from Mr. el-Sisi, refused to provide any access, ostensibly for national security reasons.
"Those records are our heritage. They're everything about us," said Reginette Schafer, who left Egypt in 1954 and lives in Washington. "And we can't get them out."
For many, the test of Egypt's commitment to celebrating its Jewish heritage may lie in how the renovated synagogues are used: whether they remain huddled behind armed policemen, as is currently the case, or can be opened to ordinary Egyptians as a monument to a part of their culture that is as old as the pyramids.
"That's the real challenge," said Rabbi Baker. "It's the story you're telling about this community, and whether you have faith that Egyptians will see it as something positive. That's my hope."
Mrs. Wolanski, driving around the Cairo district of Heliopolis with her husband and two sons, beamed with delight when she found her old school, St. Clare's, where she had once been taught by Catholic nuns.
Later she posed for a photo outside a nearby synagogue where her father prayed, as armed policemen looked on.
A version of this article appears in print on, SectionA, Page13of the New York editionwith the headline:For Exiled Egyptian Jews, a Homecoming and an Unlikely Welcome.Order Reprints|Today's Paper|Subscribe