Spain’s Jewish community lauded King Juan Carlos after he abdicated the throne in favor of his son Prince Felipe.

Juan Carlos on Monday made the surprise announcement that he would step down after nearly 40 years on the throne.

“Spanish Jews recognize, value and appreciate the personal role His Majesty ​​King Juan Carlos has played in the construction of the recent history of our country and his leadership in the consecration of the democratic values ​​enshrined in the Constitution of 1978 and, in particular, freedom of worship,” according to a statement released Monday by the Federation of Jewish Communities of Spain, or FCJE.

The federation’s statement said the Jewish community “remembers with special affection” the king’s 1992 visit to Madrid’s Beth Yaacov synagogue, the first visit by the king to a synagogue in the country.

On the 500th anniversary of the May 31, 1492 signing by Spanish King Ferdinand and Queen Isabella of the edict ordering Spain’s 200,000 Jews to either convert to Catholicism or leave the country, Juan Carlos and his wife, Queen Sofia, visited the synagogue. The king paid tribute to the “strength of spirit” of Spanish Jews forced to leave because the state demanded “religious uniformity,” but did not directly apologize for the expulsion.

Juan Carlos visited Israel for the first time in 1993, where he addressed the Knesset.

“To the future King Don Felipe, the Jewish community wishes you long life and a reign of peace and prosperity for the benefit of Spain and the Spaniards,” the federation’s statement concluded.