Saudi King Salman has held rare talks with the leader of the Palestinian militant group Hamas, Khaled Meshaal, who was on pilgrimage to Mecca.
Mr Meshaal “praised the positive stance of the kingdom’s leadership towards the Palestinian cause”, Saudi Arabia’s SPA state news agency reported.
It is four years since a Saudi monarch last had publicly acknowledged talks with Hamas, which runs the Gaza Strip.
Ties between Saudi Arabia and Hamas have been strained in recent years.
This was caused by the Saudi support for the Egyptian military in ousting the country’s Islamist President Mohamed Morsi in 2013.
Hamas has strong links with Mr Morsi and the Muslim Brotherhood movement.
Hamas is also traditionally aligned with Iran – the country seen by Saudi Arabia as a regional rival.
However, correspondents say that Saudi officials and Hamas are in regular contact behind the scenes.
Mr Meshaal has been living in exile in the Gulf state of Qatar since 2012, when he abandoned his base in Damascus, after Hamas sided with Syrian rebels against President Bashar al-Assad.