It is the second such ruling in Egypt since January when another 21-year-old was jailed for three years for declaring on Facebook that he is an atheist.
Judicial sources said that Sharif Gaber "was sentenced to one-year in prison for insulting Islam and promoting atheism, but could be freed on a bail of 1,000 pounds ($130, 117 euros) until his appeal trial".
The sentence was handed down on Monday by a criminal court in the northeastern city of Ismailiya, where Gaber studies literature at university.
Signup to our newsletter and follow us on Facebook and Twitter!
Human rights lawyer Ahmed Abdel Nabi, who is following the case, said Gaber was arrested in October 2013 after a complaint lodged against him by the head of the university.
"Fellow students complained to the dean about the opinions and atheism which they said he posted on Facebook, and police arrested him," Abdel Nabi told AFP.
In January a court sentenced Karim al-Banna to three years in jail after his father testified against him for announcing on Facebook that he is an atheist, Abdel Nabi said at the time.
Authorities in Egypt have stepped up measures to counter atheism, which is frowned upon by the country's conservative society.
Egypt's constitution outlaws insults against the three recognised monotheist religions -- Islam, Christianity and Judaism.