Correction Jan 20, 2017: An incorrect name was given for the wife of Ruhollah Qurbani, who was 27 years old at the time of his death.

A letter from a young woman to her fallen husband, a pro-Assad fighter in Syria, was recently published in Tasnim News, one of Iran's most prominent news agencies affiliated with the Islamic Revolutionary Guard Corps (IRGC).

"This shrine [the Zaynab shrine] is sacred ... I am worried about people who throw stones at it and so I sent you to protect it. But I, like you, are immersed in the love of Zaynab and that is what keeps me strong in your absence. I sent you on your way and you had to defend the shrine of Zaynab and I had to wait. I am satisfied and thankful to God to have lost one of the best people of my life for the sake of Zaynab and the Guide [Ayatollah Khomeini]."

The letter is signed by the wife of Ruhollah Qurbani, a 27-year-old soldier recently killed in Aleppo. Hers was just one of dozens of emotive affirmations from fallen soldiers' wives that circulated in Iran recently via the state channel Ofogh TV and Iran's video-sharing platform, Aparat.

Just before marking Ashoura last October, Ofogh TV aired a 12-part series of interviews titled Servants of the Shrine, referencing the burial shrine of the Prophet Muhammad's granddaughter, Zaynab, in southern Damascus.

Zaynab was one of the only surviving adult members of the Prophet's family after Imam Hussein's death at the hands of Yazid, a tyrannical ruler of Iraq, in the 7th-century epic Karbala battle. History documents Zaynab as a fierce, charismatic woman who boldly spoke out against the Umayyad dynasty - Syria's powerful rulers at the time - and Iranian soldiers currently fighting with Syrian President Bashar al-Assad have mobilised into a battalion unit named Defenders of Zaynab.

"To understand the political motivations of the country, you have to understand its revolutionary underpinnings in 1979 when it rose up against the Shah and his Western allies," Mohammad Marandi, an associate professor of literature and Orientalism at the University of Tehran, told Al Jazeera.

"Karbala is a theme [based on] oppressed versus oppressor. There was a war after [the revolution] for eight years and then there were sanctions ... Shia religious leaders speak about Hussein in a way that resonates throughout their lives. It's taught as a way to stand up against oppression."

Powerful as the Karbala narrative is, it is not the only reason why thousands of Iranians are choosing to help prop up the Syrian leader. Political and economic factors, and even the threat of deportation, are all crucial motivators.

According to analysts, Iran, a Shia-majority country, has a deep-seated fear of the rise of groups such as the Islamic State of Iraq and the Levant (ISIL, also known as ISIS) and al-Qaeda, which have repeatedly targeted Shia Muslims. "If Syria falls, Iran will have to fight these groups within its borders," Marandi said.

Some younger people are still influenced by [Iraq-Iran] war legends. They didn't have a chance to be present in those wars, so they feel they owe it to those heroes and martyrs. Hosein Ghazian, Washington-based Iranian sociologist

Iran has had a growing and increasingly visible presence in Syria since the Arab Spring in 2011. What began as technical assistance and encouragement to the Lebanese armed group Hezbollah, has gradually evolved into thousands of Iranian fighters crossing the border into Syria to overtly fight in a war that Supreme Leader Ayatollah Ali Khamenei describes as one between Islam and "disbelievers".

"The door for martyrdom, which was closed by the end of the Iranian-Iraqi war, is now open in Syria," Khamenei declared during a ceremony marking the death of 46 Iranian soldiers in Syria in February 2016.

"Youth have persistently called for going to the battlefield in Syria, where Islam is fighting kufr [disbelievers], as was the case during the Iranian-Iraqi war," he added, warning that if youth failed to join the fight in Syria, "the enemy will attack Iran."

Ali Akbar Velayati, a former foreign minister and adviser to Iran's supreme leader, has also stressed Syria and Iran's close alliance in jointly resisting Israel. "Syria is the golden ring of [the chain of] resistance against the Zionist regime," Velayati said in 2012. "Syria has demonstrated its resistance against the Western states and Zionists through its support for Lebanon and Gaza."

For some recruits, fighting ISIL in Syria is a way to help stem the group's spread. Others see it as an opportunity to honour the tens of thousands of Iranian soldiers who died in the crippling eight-year Iran-Iraq war - or as one sociologist puts it, being "present" for what they believe is a sacred war.

"In Shia culture, 'presence' and 'absence' [in a holy war] - like what Husayn and his followers experienced in Karbala - is a very crucial concept to understand. The fighters' motivations are a combination of religious beliefs and social awards," Washington-based Iranian sociologist Hosein Ghazian told Al Jazeera.

"By being 'present' in Syria, they receive more attention among people with the same beliefs … people who live with these fighters in a rather closed community. This is why you can see some more famous religious older people who have travelled for just a couple days in Syria - not to the front line - but in a secure place," he added, citing countless online videos and selfies of celebrities dressed in army gear.

Haj Saeed Haddadian is among many religious performers in Iran who have played a key role in drumming up enthusiasm among volunteer fighters. "Their selfies and pictures show they are fully armed as if they are in the heat of Syria's civil war as a fighter," Ghazian said.

Meanwhile, those perceived to be absent in Syria could feel, or be led to feel, ashamed for not defending Imam Hussein's legacy and the shrine of Zaynab. "Some younger people are also still influenced by [Iraq-Iran] war legends. They didn't have a chance to be present in those wars, so they feel they owe it to those heroes and martyrs."

A foreign fighter's experience serving in the IRGC, however, can be starkly different. About three million Afghan refugees currently reside in Iran, and discrimination against them is well documented.

WATCH: Why is Iran backing Syria's Bashar al-Assad?

According to reports by human rights researchers and journalists, recruitment of Afghan fighters can take place anywhere from mosques in Iran to Shia neighbourhoods across Afghanistan.

"In many Afghani towns there are Shia mosques," an Afghan returning soldier said in an exclusive interview with the UK-based Kayhan newspaper. "The imams and prayer leaders give sermons about these issues and if anyone wants to volunteer, they arrange contacts with the IRGC. We travel by land from Afghanistan to Tehran."

For some, the fear of deportation looms if they choose not to serve in the army. Last May, a bill was passed by the Iranian parliament, which permitted family members of slain foreign soldiers in Syria who reside in Iran to be granted immediate citizenship.

They did not give us a choice; they forced us to train and fight. They said: 'You will fight in Syria and become a martyr, and that is a good thing.' Masheed Ahmadzai, former detainee

In other cases, Afghans have reportedly been coerced to take up arms in Syria. A report by Human Rights Watch released last January provided detailed reports of Afghan fighters who were recruited by the IRGC.

Masheed Ahmadzai, a 17-year-old Tehran resident who arrived last year on a rubber boat at the Greek island of Lesbos, told researchers that he had been living undocumented for four years and was working in construction when police detained him and his cousin.

He said that police took them to a military base, where numerous other Afghanis and Pakistanis were being detained, and military officers selected the men most physically fit.

"The military officers separated us into those fit to fight, and those not fit to fight," he said. "They took me with a group of 20 men, but did not select my cousin and deported him to Afghanistan …They did not give us a choice; they forced us to train and fight. They said: 'You will fight in Syria and become a martyr, and that is a good thing.'"

EXPLAINER: Syria's civil war

While many of Iran's fighters in Syria register in the Basij, a paramilitary volunteer militia operating under IRGC, thousands of others serve as paid soldiers under the IRGC's Fatemiyoun unit, mainly made up of Shia from the diaspora in Iran.

Estimates of fighters' salaries have ranged from around $500 to $750 a month, according to media reports. But in a recent interview with reporters from Iran, Brigadier-General Mohammad Ali Falaki, a retired IRGC commander who was deployed to Syria, said that foreign fighters actually earn just $100 a month - a figure some speculated was being played down because of the struggling Iranian economy.

Falaki also acknowledged the insufficient support in Iran for Afghan refugees, which he viewed as an untapped pool of recruits.

Besides being a significant regional force in the Middle East, the IRGC wields huge political, economic and ideological power throughout Iran. Whether its fighters are incentivised by money, citizenship, or greater social acceptance, one thing is clear: It does not need to look far for support.

But in the eyes of some analysts, the geopolitical costs for Iran's military involvement in Syria have been high.

"Iran's actions in Syria totally undermine their claim to representing the global Muslim community," said Mohammad Fadel, an associate professor of law at the University of Toronto. "It reinforces the idea that Iran is a clearly sectarian state."

For a long time, Fadel points out, there were two different narratives about Iran - that it was a sectarian state. Then there was another that viewed Iran as a kind of revolutionary, anti-imperial state - one that supported Muslims and self-determination and was more or less an ally of the people. "Iran's intervention [in Syria] completely destroyed that second narrative."

The overt religious rhetoric about protecting the shrines of the Prophet's family reinforced their sectarian stance, Fadel added. "It implied that those who were against Assad were against the Prophet's family. It's obvious there is a strand in the Sunni community who object to shrines, but to then paint the entire Syrian revolution with that brush - and then imply that protecting these shrines merits a type of violence - is something else."