BERLIN — John F. Kerry has done town hall meetings in Manchester, N.H. He has fielded questions about corn subsidies from voters in Des Moines, and stumped in cities across Massachusetts.

But on Tuesday, the new secretary of state brought those political skills to Germany, holding a town hall meeting here with students in the foreign country where Kerry himself spent time as a child. He cracked jokes, often at his own expense. It was, as he made clear on this third day of a whirlwind tour of European and Middle Eastern capitals, an emotional journey.

Kerry had returned to a city he knows well. Everywhere he stopped on Tuesday — the US Embassy, the town hall, and meetings with German leaders — Kerry mentioned his personal connections to the city. He told stories of his boyhood in the city in the 1950s, when his father was a foreign service officer advising US officials about a variety of legal actions.

One day, Kerry rode his bicycle over to East Berlin.

“I saw the difference between the east and the west. I saw people wearing darker clothing,” Kerry said. “There were fewer people in the street, there were fewer cars. I didn’t feel the movement or the energy that existed elsewhere.”

But when he got home, his father grew angry with Kerry. It could have created an international incident. His father was in charge of upholding laws, and his son was breaking them.

“So I lost my passport, and I was grounded,” Kerry said. “And I never made another trip like that.”

That memory guided him as he arrived in this city Monday night. He walked up to the Brandenburg Gate, the symbol of the Cold War divide between East and West Berlin, and snapped a photo with his Blackberry. Kerry, whose paternal grandparents were raised in Europe and converted from Judaism to Catholicism at a time of virulent antisemitism, also walked through a Holocaust memorial.

During the town hall meeting, held at a crowded Internet café, Kerry held a wireless microphone in his left hand, gesturing with his right. He paced the stage, with his jacket draped over a stool. Several dozen students sat on white foam blocks and couches, with bottles of water, cups of coffee, and Macbook laptops in front of them.

To excited applause and laughter, Kerry started the town hall with several phrases in German.

“I want to hear from you,” he said. “I don’t want to just speak at you.”

“Let’s go,” he said eagerly, removing his suit jacket. “Who’s first?”

He spoke about the illusive effort to broker peace between the Israelis and Palestinians, the ongoing conflict in Mali, and what he plans to do about Africans exploited by mining. He promoted a proposal for a trade agreement between the United States and the European Union, and he outlined the reasons why he opposed the Vietnam War. He batted away a question about whether he would push the Russians to be more accepting of gays and lesbians.

Later, a woman mentioned that she was majoring in film studies.

“Did you watch the Academy Awards?” Kerry asked.

She said she did.

“And did the right movie win?” he inquired.

She had wanted “Les Miserables” to win best picture, not “Argo.”

But the most profound moment of the town hall came when a woman in a light blue headdress rose and asked Kerry what he thought about when he saw people like her — and what he viewed as the difference between Muslims in Germany and the United States.

Kerry answered that he didn’t know enough about the German Muslim community to make a comparison but he talked about the American Muslim community.

“As a country, as a society, we live and breathe the idea of religious freedom and religious tolerance. . . . In America, you have a right to be stupid if you want to be . . . And we tolerate it. We somehow make it through that. Now, I think that’s a virtue. I think that’s something worth fighting for.”

Kerry added that he was fascinated by religion as a window to the world, saying that he’s currently reading “No god but God,” a book by Reza Aslan on the evolution of Islam. If he went back to college today, he said, he would probably major in comparative religion and comparative literature.

He went on to discuss Massachusetts, and said that one of his maternal ancestors, John Winthrop, gave a speech to pilgrims traveling to what became the Bay State about establishing “A city upon a hill.”

But, Kerry said, “It turned out that in Massachusetts, they weren’t as tolerant as they thought they were going to be. They had witch hunts in Salem, Mass., and they burned people at the stake.”

“Finally, after years of working on it, we kind of worked the balance,” he said. “I can say to you that our country is incredibly tolerant of people of all walks of life and different philosophies and religions.”

One student asked him why he opposed the Vietnam War, in which he served as a naval officer.

“I thought it was a mistake,” he said. “And so, when I came back to America as a young veteran, I led veterans against the war . . . Anyone who has been to war should hate war.”

“I am not for war as a choice,” the nation’s top diplomat said, underscoring what doubtless will be a theme of his tenure. “War is a failure of diplomacy.”