The incident took place at a village in the Nile Delta governorate of Sharqiya, situated 65 kilometers (40 miles) north of the capital Cairo, late on Friday.
Clashes came after a 28-year-old person allegedly made derogatory remarks about Morsi on Facebook, prompting a spat with a 22-year-old student — a supporter of Morsi and son of a local member of the Muslim Brotherhood’s Freedom and Justice Party.
Shortly afterwards, the row escalated into a fight in which the student fatally shot his challenger and another man who intervened to stop the quarrel.
Later on, some angry villagers set fire to the house of the culprit, after which they caught and beat him to death in the absence of the police.
Egypt has witnessed continuing anti-government protests since Morsi took office last June. The opposition accuses the president of leading a dictatorial government and deviating from the 2011 revolution that toppled the Western-backed regime of the former Egyptian dictator, Hosni Mubarak.