Rogen and his wife, Lauren Miller, asked for the order after Yasin Ajani, 30, allegedly tried to gain access to the couple's residence on two occasions by claiming he was delivering a package.
Miller said in her court petition she had been seriously unnerved by the incidents, E! News said.
"I live in fear that he will return," Miller wrote. "I have difficulty sleeping and look for (Ajani) whenever I come and go from my house."
Justin Bieber crashes Drake Bell's album release party
Members of Congress to keep receiving porn magazine