The African National Congress (ANC) invited exiled Hamas leader Khaled Meshaal and colleagues from the Islamist militant group on a three-day visit to South Africa, sparking strong criticism from Israel.
President Jacob Zuma exchanged gifts with Meshaal on Monday and signed a letter expressing support for Palestinians.
"It is state-sponsored crime from the people of Israel on Palestine," said Marius Fransman, a provincial ANC chairman, drawing cheers from the crowd in Cape Town.
"People close their eyes, we are taking a stand. We have to reaffirm the message of the unity of the oppressed masses."
Hamas supporters lined the streets near the venue, waving the organisation's white-and-green flag.
Addressing the rally, Meshaal compared the Palestinian cause to the anti-apartheid struggle in South Africa.
Signup to our newsletter and follow us on Facebook and Twitter!
"South Africa, you have achieved your freedom, the people of Palestine are aspiring to attain their freedom," he said.
Violent protests that first began in annexed east Jerusalem and the occupied West Bank have in the past month spread to Gaza, were Hamas has called for further unrest.
"The uprisings shall continue until the freedom is achieved and the land is for Palestine and its people," Meshaal told the audience of a few hundred people.
"Do not expect that they should stop with the uprising, do not expect that they should stop with the resistance."
The Israeli foreign ministry on Monday had summoned South Africa's deputy ambassador to protest against Meshaal's visit, which it said "encourages terror by giving some legitimacy to a terror organisation."
The European Union and the United States have blacklisted Hamas, which runs the Gaza Strip, as a terror organisation.
Nelson Mandela, the late South African president and ANC leader, was an ardent supporter of the Palestinian cause and a champion for Middle East peace.