Print margin and skew describe an image placed crookedly on the printed page. It is one of the most common defects in electrophotographic printers and dramatically affects print quality. It primarily might occur when using a two-sided printing module on the printer. To solve or correct the print margin and skew error, we should first accurately detect the print margin and skew on the printed page. This paper proposes a method to accurately detect the print margin and skew based on the Hough Lines Detection algorithm. There are three steps of this print margin and skew detection method. We first project the digital master images into the scanned test image with master image edges. The second step is the most challenging part of designing this method because all of our scanned test pages had only two or three and barely visible edges of the printed paper to the naked eye. We use an image processing method and Hough Lines Detection algorithm to extract the paper edges. The third step uses the projected master images edge and the extracted paper edges to calculate the print margin and skew result. Our algorithm is an efficient and accurate method to detect print margin and skew errors based on factual scanned image verification.