In Iran the government was quick to condemn the execution and the Supreme Leader, Ayatollah, Ali Khamenei, railed that the Saudis will pay a "High Price". This was followed by the burning of the Saudi embassy in Teheran and the expulsion of Iranian diplomats from Saudi Arabia. The war of words ( at this point) has picked up with the Saudis accusing the Iranians of supporting "terrorism" and the Supreme Leader warning of "divine revenge".
The Saudis are the leader of the Sunnis, which make up 85% of Muslims spread across the globe from Arabia to Indonesia to Pakistan, India, Bangladesh, Malaysia and elsewhere, while Iran is the center of the Shiites, with 60% of Iraq and a minority in Syria, Lebanon and Yemen and Bahrain. The Saudis see the Iranians as a threat to their power and influence in the region, what with the Iranians supporting the Shia government in Iraq, propping the Assad government in Syria, assisting the Houthis in Yemen and working closely with Hizbollah in Lebanon.
The Iranians are the leader of the Shiites and they feel encircled by the Saudi-led Sunnis. They have become more emboldened after the signing of the nuclear agreement with the USA. This will mean that in return for restricting their nuclear programme, the economic embargo that was imposed on them will be lifted and so they can sell their oil and gas, have the banking assets unfrozen and open themselves up to the world for trade, investment and tourism. Billions will pour into their coffers and with their economy booming and their young and educated population ( in tune with the outside world), prosperity, power and influence are at hand.
The Saudis with their oil wealth dwindling ( with the rapid fall of price), fear that their power and influence are waning ( their closed society and repressed population are ripe for explosion and that's why Nimr al Nimr and his "kind" are harshly dealt with), as paranoia haunts the Kingdom. It is a fight for survival for their way of life so greatly influenced by their Wahabbist brand of Islam and they see Iran as the external threat and that the signing of the nuclear agreement and America's efforts to work out a peace agreement to end the conflict in the region and defeating ISIL and its "terrorist" ideology, as an advantage to Iran.
Where will this end? With hardliners in both countries; with historic divisions in religion ( Sunni vs. Shia ); with regional ambitions clashing in Iraq, Syria and Yemen, and with the USA'S influence especially with Saudi Arabia lessening due to Saudis anger over the nuclear deal and suspicion about the "interests" of the Obama administration, it is tinderbox ready to explode.
A little miscalculation; a tiny spark is all it takes.