How to Fix Formatting Issues After Converting an Image to Excel

Image-to-Excel conversion often leads to misaligned merged cells, columns that don't line up, and lost borders and fonts. This article walks through the troubleshooting and repair steps in order from easiest to hardest, and explains how to reduce rework at the source.

Key points of this article

  • First determine whether the layout structure is wrong or the recognized content is wrong; the fixes differ, so don't re-layout right away.
  • Column misalignment and merged-cell offset usually stem from skew or row/column misjudgment; fix the column lines first, then fix the merges.
  • Border and font loss are style problems; handle them with a unified setting, which is much faster than editing cell by cell.
  • Recognized numbers and formulas must be checked item by item; correct formatting does not mean correct content.
  • The straighter the original image and the more complete the table boundaries, the less cleanup the conversion requires.

Many people hand screenshots or photos of tables to recognition tools, and when they get the Excel file, they find that: data that should be on one row has been split across two rows, merged header cells are misplaced, column widths are uneven, borders are only half present, and fonts have reverted to the default style. The table contents all appear to be there, but they can't be used directly and have to be corrected cell by cell by hand.

This is written for people who have already converted images into Excel and are now cleaning up the layout. After reading it, you should be able to tell which kind of problem is causing the mess, know what to fix first and what to fix later, and understand how to reduce errors at the source when using the PDF editor in the OmniDoc desktop client to run OCR and export to Excel.

If the recognition result contains almost no text, or large passages are misread, the problem lies in the recognition stage, and simply adjusting the formatting will be of little use. You should first go back to the original image and check its clarity.

Image-to-Excel formatting is messed up—what should I do? One-sentence answer

First determine whether the problem is "wrong structure" or "lost styling." Fix structural issues first, then styling issues, and check the content last.

Your situationRecommended PracticesCause
The original image is a clear screenshot, and the table lines are complete.After recognition, check each column item by item, and first fix the column lines and merged cells.The structural information is sufficient, and the amount of manual patching is small.
The original image is a photo or scan, with skew and shadows.Rectify the image or retake the photo first, then recognize it.Skew makes the row and column judgment shift overall, and manually moving things around in Excel is very time-consuming.
The original is a PDF, and the tables are only image layers.Perform OCR in a PDF editor, then export to ExcelFirst generate the text layer; the row and column structure exported this way is usually more complete than what you get from converting a direct screenshot.
The table has no border lines; the columns are separated by whitespace.After recognition, first unify the column widths, then add the merged table headers.Column boundaries in borderless tables are inferred, so they are prone to misalignment.
Tables are used for calculations or reporting.After fixing the layout, check the numbers item by item, then add the formulas.The cost of digit recognition errors is high, so it must come before calculation.

First, determine which type of problem it is

Before you start fixing, check the table below to find the symptom, so you don't waste time going in the wrong direction.

SymptomsCommon causesHow do I confirm?
One row of data was split into two rows.Row height detection is incorrect, or line breaks inside a cell are being treated as row breaks.Compare against the original image: is all of this row's content between the same pair of horizontal lines?
Merged cell position offset or disappearanceThe cross-column header was not recognized as a merged cell.Select the area and check whether it has actually been merged, then compare it with the header width of the original chart.
Shift the entire table left or rightColumn-line offset caused by image tilt or perspective distortion during captureCheck whether the first row and the last row's columns shift in sync, and whether their offsets are the same.
Borders and shading have disappeared.Recognition mainly retains the text, but the line styles were not fully carried over.Check whether the lines in the original image are very thin or the color is very light.
All fonts and font sizes are the same.When exporting, the default style is used, and the original fonts are not preserved.Compare the font size difference between the title and the body text of the original image.
Digits get garbled or the decimal point disappearsCell is formatted as text, or characters are misrecognizedCheck the cell formatting, and spot-check a few numbers against the original image.

Item-by-Item Troubleshooting and Fixing

I suggest handling it in the following order: first fix the structure, then fix the styling, and finally check the content. That way, each step's changes won't be overturned by the operations that follow.

  1. Compare against the original image and note the total number of rows and columns and the header structure. You can sketch a rough layout on a blank Excel worksheet.
  2. Check for overall offset. If the columns in the first and last rows are shifted in the same direction, the image itself is skewed. Go back to the source image, straighten it, and then recognize it again. This is easier than moving columns one by one in Excel.
  3. Adjust the column widths so the column boundaries line up with the vertical lines in the original image, then split or delete any extra columns.
  4. Remove the incorrect merged cells, then re-merge them according to the header structure of the original. When merging, note that Excel keeps only the content of the upper-left cell and clears data in the other positions, so before merging, confirm that those positions are actually empty.
  5. Check for rows that were split apart. Merge lines that were broken up by line breaks within a cell back into a single row, and standardize the row heights.
  6. Set borders, fonts, font sizes, and alignment all at once rather than cell by cell; otherwise new inconsistencies will appear quickly.
  7. Finally, verify the numbers: check decimal points, minus signs, thousands separators, and cell formats, and compare key data and totals against the original image.

When the original is a scanned or photographed PDF

If the original file is itself a PDF and only the table has no text layer, you can open the PDF in the OmniDoc desktop client (download address: download.omnidoc.top), use the editor's OCR feature to recognize the scanned pages, and then export to Excel. After exporting, you still need to check the column lines and merged cells following the steps above, because OCR results cannot guarantee that they fully match the original table.

When the original is only an image

The image has no text layer, so you cannot run OCR directly in a PDF editor. You can first save the image as a PDF (most operating systems can do this), and then apply the methods above. Alternatively, retake the screenshot, making sure the table is fully captured on all sides, without compression, and without cropping the table borders.

OCR and image recognition can both make errors. For important data, please verify each item against the original document.

How to Avoid Recurrence Next Time

  • Before conversion, tidy up the source image: crop away extra margins, make sure all four outer borders of the table are complete, shoot as square-on as possible, use even lighting, and keep shadows off the table.

Use a clear screenshot whenever you can instead of taking a photo. The lines and text boundaries in a screenshot are usually much more regular than in a phone photo.

For tables without ruling lines, first add a few vertical lines manually on the original image or the screenshot, then run recognition. That way the column boundaries don't have to be inferred.

Follow a fixed order of operations: fix rows and columns first, then unify the styling, and finally check the numbers. If the order is reversed, style adjustments can easily be lost once the structure is repaired.

For tables that recur often, keep a template with column widths and styling already set. Paste later recognition results into the template so you have fewer repeated adjustments.

Save two versions, one from before recognition and one from after, so you can trace back when something goes wrong, rather than continuing to patch a file that has already been messed up.

❓ Frequently Asked Questions (FAQ)

1. Can I restore the original formatting with one click after converting an image to Excel?

Usually it cannot. Recognition tools can only infer rows, columns, and text from the image. Color shades, thin lines, and blank spaces in the original may not be fully reproduced, so in most cases manual completion is needed.

2. The table has no border lines, and after recognition the columns are all jumbled. What should I do?

Column boundaries in borderless tables are inferred from whitespace, which can easily cause misalignment. It is recommended to manually add a few vertical lines to the original image before recognition, and after recognition, correct the columns one by one in Excel to match the number of columns in the original table.

3. Once the formatting is fixed, do the numbers still need to be checked?

Formatting being correct does not mean the content is correct. During recognition, similar-looking digits may be misread, or decimal points may be dropped. Key figures and total rows should be checked item by item against the original image.

4. Can data be recovered after unmerging cells?

When cells are merged, only the content in the upper-left cell is kept; data in the other positions is cleared during the merge. If the file has not been saved yet, you can restore it with Undo; if it has already been saved, you should go back to the original drawing and re-enter this data.

5. Can a scanned PDF be converted directly to Excel?

Scanned PDFs have no text layer, so exporting them directly usually doesn't produce usable results. First use the OCR feature in a PDF editor to generate a text layer, then export to Excel; the results will be much better. After exporting, you still need to check the structure step by step.

📝 Summary

What should I do if the format gets messed up after converting an image to Excel? First identify whether the problem is structural misalignment, lost styling, or digit recognition errors, then work through them in the order of column lines, merged cells, styles, and number verification. At the source, use a clear, upright original image, or use OmniDoc's OCR and export features, which can noticeably reduce rework.

Open OmniDoc and export the PDF content as an editable file

Updated 2026-11-29