The 30-year-old Hartnett, who is in London starring in a stage version of "Rain Man," was reportedly unaware that his actions with the unidentified woman were caught on security cameras having sex while hotel employee watched.
A source from the hotel told Britain's Daily Mirror newspaper Hartnett drew the curtains in the library of a Soho hotel, but did not spot the security cameras.
"Josh and the girl were getting pretty hot and heavy," the source said. "Their every spit and cough was recorded and cringing hotel workers saw all of Josh's X-rated moves."
The newspaper reports Hartnett, who also starred in "Pearl Harbor," "The Black Dahlia" and "30 Days of Night," was asked by hotel staff to take his sexual escapades elsewhere in the future.