Iran President Hassan Rouhani's son-in-law resigned on Monday just two days after his appointment as head of Iran's geological survey sparked accusations of nepotism, official news agency IRNA reported.
Kambiz Mehdizadeh, in his early thirties and reportedly married to Rouhani's daughter in a low-key wedding this August, was appointed to the senior position in the industries and mining ministry on Saturday.
The move sparked criticism on social media and from some lawmakers.
"I thank you for finding me worthy and inviting me to work alongside you in this ministry, but I ask to be relieved of my service so that I can continue my scientific and research activities," Mehdizadeh wrote in a resignation letter, according to IRNA.
Mehdizadeh is a PhD student in petroleum engineering, who has also served as an advisor to Iran's oil ministry, taekwondo federation and national youth organization, according to the conservative Tasnim news agency.
The minister who appointed him, Reza Rahmani, defended his choice just hours before the resignation, saying Mehdizadeh was "chosen based on his competence and being the president's son-in-law had nothing to do with it," according to IRNA.
Iranians on social media renewed criticism of nepotism that had spread last year with the hashtag "#good-genes" -- a reference to the son of a prominent reformist politician who attributed his business success to inheriting "good genes" from his parents.
"I had no idea even sons-in-law could inherit #good-genes!" wrote one Twitter user on Sunday in reference to Mehdizadeh's appointment.
Earlier in the summer, another online campaign called on senior officials to come clean about the privileges their children enjoy, particularly those studying in the United States and other Western countries.
The campaign titled: "#Where-is-your-kid" pressured several government figures to respond, including Foreign Minister Mohammad Javad Zarif, who said his children had returned to Iran after studying abroad.
This is not the first time Rouhani is accused of nepotism and corruption.
Rouhani's brother, Hossein Fereydoun, served as his assistant and a member of his team before he was detained for corruption by the Iranian Revolutionary Guards Corps (IRGC) intelligence service and court orders.
The nephew of the Iranian president heads the People's Relations Department at his office and is the adviser to his chief of staff.