How to Remove Ruled Lines and Jagged Edges from a Scanned PDF
Question details
The user needs to clean up a 100-page color scanned PDF by converting it to black and white, removing ruled notebook lines, and cropping out jagged scan edges.

- Product
- PDF Editor
- Device & OS
- not provided
- Scenario
- Editing and formatting a large scanned PDF to improve readability and give it a clean, professional appearance.
- Observed behavior
- The current PDF retains the color, ruled notebook lines, and rough edges inherited from the original physical scan.
Because automated OCR and background removal processes can sometimes alter the layout of heavily formatted documents, we highly recommend working on a backup copy of your 100-page PDF file.
Convert Colors and Use OCR to Clean Up the PDF Background
Use your PDF editor's color conversion and Optical Character Recognition (OCR) tools to separate the text from the unwanted background lines.
By converting the scanned document to grayscale and running OCR, the software can identify the actual text. Once recognized, the text becomes a separate layer from the background, allowing you to delete the ruled lines and messy edges without losing the content.
Open the Print Production or Color Management tools in your PDF editor. Select the 'Convert Colors' option to change the entire document from color to grayscale, making it easier to distinguish text from the background.
Navigate to the 'Scan & OCR' or 'Recognize Text' tool. Run the OCR process on the document so the software can convert the scanned images of words into editable, selectable text.
Open the 'Edit PDF' tool. Click on the background image elements (which now include the ruled lines and jagged edges) and press the Delete key to clear them, leaving only the recognized text.

Crop Pages to Remove Jagged Edges
If the primary issue is the rough, jagged edges from the scanning bed, you can uniformly crop the document margins.
Easily Clean Up Scanned PDFs with WPS Office
WPS Office offers a comprehensive PDF toolkit with advanced OCR and page editing capabilities. You can effortlessly convert scanned documents to editable text, crop out jagged margins, and manage backgrounds to make your documents look professional.
- 1. Open your scanned PDF: Launch WPS Office and open your scanned document in the WPS PDF interface.
- 2. Apply OCR technology: Navigate to the 'Tools' tab and click on 'OCR' to convert the scanned image into an editable text document.
- 3. Edit the background: Go to the 'Edit' tab, select 'Background', and remove or replace the existing background to eliminate the ruled notebook lines.
- 4. Crop unwanted edges: Use the 'Crop Pages' feature under the 'Edit' tab to trim away the jagged edges across all pages simultaneously.

Frequently Asked Questions
Why does the OCR tool fail to separate text from notebook lines?
OCR accuracy relies heavily on the contrast and resolution of the scan. If the text is handwritten, faint, or overlaps heavily with the ruled lines, the software may merge them into a single image element. Converting the document to grayscale or increasing the contrast before running OCR can improve results.
Can I automatically remove backgrounds from all 100 pages at once?
Yes. Once the document has been successfully processed with OCR and converted to editable text, you can use the 'Background' tool in your PDF editor's Edit menu to remove or apply a blank white background across the entire page range in one click.
Will converting a PDF to grayscale reduce the file size?
Usually, yes. Color scans contain significantly more data than grayscale or black-and-white documents. Converting the color profile and removing unnecessary background images like notebook lines will generally result in a much smaller and more optimized PDF file.




