"Due to demand of party leaders and workers, SP supremo will contest from both Azamgarh and Mainpuri seats," party's national general secretary Ramgopal Yadav said.
He also said that the decision to field Mulayam from seats was taken after BJP's prime ministerial candidate Narendra Modi's name was announced for Varanasi constituency, that led to "rethink strategy" in SP.
The Samajwadi Party had earlier declared Uttar Pradesh cabinet minister Balram Yadav as the party's candidate from Azamgarh, which has a sizable number of Muslim and Yadav population.
Speculations were rife regarding Mulayam's candidature from the Azamgarh Lok Sabha constituency, but senior party leader Shivpal Yadav had earlier denied it saying that there was no such proposal.
In the 2009 elections, Mulayam won the Mainpuri seat by a margin of over 1.6 lakh votes and BJP's Ramakant Yadav won the Azamgarh constituency by nearly 50,000 votes.
SP candidate Durga Prasad Yadav came third in the constituency behind BSP's Akbar Ahmad Dampi.
The decision comes after a week when party's Cabinet minister and Mulayam's brother, Shivpal Yadav last week told reporters ,"There is no such proposal yet for Netaji (Mulayam) to contest from Azamgarh".
Earlier in March, Mulayam, also known as Netaji, publicly roughed up his son and Uttar Pradesh's Chief Minister Akhilesh Yadav and senior minister Azam Khan.
Mulayam, who currently represents Mainpuri Lok Sabha constituency in Parliament, will now also contest from Azamgarh as the constituency has majority of Yadavs and Muslims.
Earlier, the party had given ticket to cabinet minister Balram Yadav from Azamgarh but local SP workers demanded Mulayam's candidature from the seat.
On February 3, while addressing an eelction rally at Gonda district in UP, Mulayam had claimed to be a 'king-maker' after the forthcoming Lok Sabha polls and said, "no government would be possible at the Centre without the support of Samajwadi Party."