The Luther actor said he is currently showing no symptoms of the virus but was tested after coming into possible contact with Covid-19.
Sharing a video of him and his wife Sabrina on Twitter, Idris said that receiving the diagnosis “sucked”.
He wrote in a tweet: “This morning I tested positive for Covid 19. I feel ok, I have no symptoms so far but have been isolated since I found out about my possible exposure to the virus. Stay home people and be pragmatic. I will keep you updated on how I’m doing. No panic.”
In the video, Idris explained he had been in self-isolation after someone he’d had contact with tested positive for the virus on Friday.
He urged people to continue social distancing and washing their hands.
He said: “There are people out there who aren’t showing symptoms and can easily spread it. So now is a real time to be vigilant washing your hands and keeping your distance.”
Hollywood stars Tom Hanks and Rita Wilson, Bond actor Olga Kurylenko, Arsenal head coach Mikel Arteta, and Chelsea footballer Callum Hudson-Odoi are among the high-profile people who have already been diagnosed with coronavirus.