My student years were a lot of fun. As young idealists. we marched, rallied and campaigned for numerous causes, but one of the major issues that stood at the heart of our radical consciousness was the South African apartheid.

It took time, but the results were astonishing and apartheid was replaced with democracy.

Last summer, when I visited South Africa for the first time, I marveled at the collapse of the mighty apartheid regime and the outstanding efforts of the new South Africa to integrate its rainbow of nations.

On Yom Kippur, we read the curious tale of Jonah and the big fish that swallowed him. At the end of the story, Jonah recants and travels to Nineveh, where he preaches powerful sermons warning of the city's imminent destruction.

His message is heard by the people who proclaim a fast day, don sackcloth and ashes and repent for their misdeeds. When the King of Nineveh hears what has happened, he joins the penitential frenzy, ordering a mass fast which includes not only people, but animals as well.

The response from Nineveh is immediate, dramatic and extreme. It is high on passion, but low on maturity. When bizarrely, the people force their animals to fast and dress in sackcloth, Jonah is unimpressed.

But God is more tolerant, conceding that although the people "do not yet know their right from their left", their actions are sincere, they are His beloved creations, and so He forgives them.

In South Africa, I saw signs of it nationwide-repentance everywhere. The old "whites only" benches have been consigned to museums; black and white people sit together in parks, universities and the judiciary.

A revolution has occurred. Human rights activists like Judge Albie Sachs who were once hunted and persecuted by the apartheid regime are now national heroes, making extraordinary contributions to the New South Africa.

A nation can repent.

The South African revolution remains young and in some senses immature. Violence is a continuous threat and AIDS is still rampant. In Durban, all of the road names were changed overnight, replacing the old "white names" with new black ones. The results are chaotic as drivers and pedestrians have no idea which streets they are traversing.

Yet, there is something thrilling and uplifting about a nation which repents. England too, is going through a process of national introspection as it tries to understand the violent riots which recently erupted on its streets. And the Arab spring has elements of penitence as nations rise up against unjust, authoritarian regimes.

On Yom Kippur, God judges not only every individual, but every nation too. (Rambam Laws of Penitence 3: 2) One of the most radical, exciting and enticing ideas at the heart of religious Zionism is the concept that the Jewish people must strive to build the most moral, ethical society in the world.

We are all very proud of Israel and its extraordinary achievements. Against all the odds, we have built an outstanding democracy and performed miracles in technology, Torah study, integration of different peoples and ethnic groups and so much more.

Nevertheless, as Yom Kippur approaches, we are not exempt from national stock-taking.

The more religiously observant we are, the more concerned we should be about the moral level of our nation. We must never lose sight of our national mission to be the most righteous of the nations. If others see imperfections in our state, we should listen carefully before dismissing their criticism.

Smugness is the enemy of true piety. Introspection, repentance and striving for improvement are the hallmarks of our identity and the fuel of Jewish moral achievement.

So as Yom Kippur approaches, let us be open to criticism, regardless of its source. Let us be sure to ask searching questions about how we treat "the strangers who dwell amongst us", the poor and the vulnerable. Let us investigate the flaws in our society and correct them.

We may not achieve perfect penitence, but every effort that we make is recognized by God and brings us closer to fulfilling the mission of the Jewish people – because a nation can repent.

Rabbi Gideon Sylvester is the British United Synagogue's rabbi in Israel and director of the Beit Midrash for Human Rights at the Hillel House of Hebrew University in Jerusalem.