As ISIS members say they want to ‘sack the holy city’, Riyadh calls in military assistance from its close allies to shore up the porous 500-mile border

Pro-ISIS graffiti begins to appear around the kingdom while residents in parts of Riyadh woke in June to find jihadist leaflets on their car windscreens

Saudi Arabia has deployed thousands of troops from Egypt and Pakistan along its frontier with Iraq, amid fears of invasion by the al-Qaeda splinter group that has declared a radical Islamic state across the border.

Panicked by the advance of the Islamic State of Iraq and al-Sham (ISIS), Riyadh has taken the drastic step of calling in military assistance from its close allies to shore up the porous 500-mile border, Gulf security sources said.

Saudi Arabia spent an estimated £35 billion on defence last year, leapfrogging Britain as the world’s fourth-largest military spender. This massive outlay highlights Riyadh’s unease about whether its defences would hold if the jihadists launched a direct attack.

Uppermost among Saudi concerns is the defence of Mecca. Members of ISIS have made it clear online that they want to sack the holy city. “The kingdom is calling in favours from Egypt and Pakistan,” an adviser to the Saudi government said. “No one is certain what Isis has planned, but it’s clear a group like this will target Mecca if it can. We expect them to run out of steam, but no one is taking any chances.”

ISIS, which now calls itself Islamic State, seized large swathes of northern and western Iraq in a lightning military offensive in May and June, triggering panic throughout the region. The group has since declared an Islamic state, or caliphate, launching a reign of terror on land that it controls in Iraq and Syria.

Saudi Arabia has been strengthening its border defences since the crisis began. King Abdullah promised that “all necessary measures” would be taken to defend the world’s largest oil producer and 30,000 extra troops were deployed along the Iraqi frontier in July. It now appears, however, that many of those soldiers were foreign.

With ISIS consolidating its gains, its advance has slowed and the threat of a cross-border attack has receded for now. However, Theodore Karasik, of the Institute for Near East and Gulf Military Analysis in Dubai, said, “No one has taken any initiative to root these guys out. Once they have consolidated, there is a danger they will try to go back into the kingdom.”

Rather than a cross-border assault, however, the greater danger appears to be an attack from within. Saudi Arabia fought a decade-long struggle against al-Qaeda after 9/11 and there are signs that a fresh wave of attacks could be imminent. Thousands of Saudis have fled abroad to join the jihadists, raising fears of a backlash when battle- hardened fighters return home.

The kingdom announced in May that it had foiled a plot to assassinate senior Saudi officials and religious figures by terrorists linked to Isis. Pro-Isis graffiti has begun to appear around the kingdom and residents in parts of Riyadh woke in June to find jihadist leaflets on their car windscreens.

A spokeswoman for the Egyptian government denied that Cairo had sent troops to Saudi Arabia, but said the two allies remained in constant contact about the terrorist threat. “The security of the Gulf impacts on the security of the entire Middle East,” she said. Saudi government spokesmen could not be reached for comment.