Fix Excel Page Numbers Changing When Exporting to PDF
Question details
The user needs to fix an issue where page numbers change or become mismatched when converting an Excel workbook to a PDF file.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Exporting a multi-page Excel workbook to PDF format for sharing or printing.
- Observed behavior
- Page numbers in the exported PDF do not match the page numbers shown in the Excel workbook, particularly around pages 12, 13, and 14.
Verify that your default printer drivers are up to date, as Excel relies on printer settings to calculate page layouts and breaks during the PDF export process.
Configure PDF Export Settings to Include the Entire Workbook
Page numbering discrepancies often occur because Excel defaults to exporting only the active sheet. Changing the export option to 'Entire workbook' ensures continuous numbering.
When exporting to PDF, Excel's default behavior might slice the document based on active sheets. By explicitly telling Excel to publish the entire workbook, the page numbers will generate in the correct sequence.
Click on 'File' in the top-left corner of Excel, then select 'Save As' and choose your desired destination folder.
In the 'Save as type' dropdown menu, scroll down and select 'PDF (*.pdf)'.
Click the 'Options...' button located just below the file format dropdown.
Under the 'What to publish' section in the dialog box, select the 'Entire workbook' radio button and click 'OK'.
Click 'Save' to export the file. Open the resulting PDF to confirm that the page numbers now match your Excel workbook.

Adjust Manual Page Breaks and Unhide Data
Hidden rows, hidden columns, or manual page breaks can cause unexpected shifts in page numbering that only become visible in the final exported PDF.
Export Workbooks to PDF Perfectly with WPS Office
Avoid unexpected layout shifts and page numbering errors by opening your spreadsheet in WPS Office. Its native PDF conversion tool accurately preserves your print layout, ensuring your final PDF looks exactly like your workbook.
- 1. Open your file in WPS Spreadsheet: Launch WPS Office and open the Excel workbook that is experiencing page numbering issues.
- 2. Access the Export feature: Click on the 'Menu' button in the top left corner, hover over 'Export to PDF', and select it.
- 3. Configure export settings: In the dialog box, select 'Entire Workbook' under the Export Range options to ensure page numbers flow continuously.
- 4. Export the document: Click the 'Export to PDF' button. Your file will be saved with perfect formatting and accurate page numbering.

Frequently Asked Questions
Why do my Excel page breaks move when saving as PDF?
Excel recalculates the page layout based on the default printer driver installed on your computer. If the printer settings have different margins or scaling than what is displayed on your screen, page breaks and page numbers can shift during the PDF conversion.
How do I force my Excel sheet to fit on a specific number of pages for PDF export?
Navigate to the 'Page Layout' tab, locate the 'Scale to Fit' group, and adjust the 'Width' and 'Height' dropdowns to '1 page' (or your desired number of pages) before exporting to PDF.
Can hidden columns affect PDF page numbering?
Yes. If export settings or the defined Print Area inadvertently include hidden elements, or if a manual page break is attached to a hidden row, it can alter the layout and cause the subsequent page numbers to be offset.
How can I check my page numbers before exporting to PDF?
The most accurate way is to use the Print Preview screen (File > Print). The preview shown here is exactly what the PDF engine will process, allowing you to catch numbering errors on specific pages before saving the file.




