Formatting Issues

Fix Excel ColumnWidth and Width Values Not Matching

Muhammad TalhaMuhammad Talha Oct 26, 2026 868 views

Question details

The user needs to accurately set a column's width in points, but Excel's ColumnWidth and Width properties do not match or scale linearly.

Why Excel ColumnWidth and Width Values Do Not Match (And How to Fix It)
Product
Microsoft Excel
Device & OS
not provided
Scenario
Attempting to standardize column dimensions programmatically using VBA, where exact point measurements are required for reporting or printing.
Observed behavior
Setting the ColumnWidth property (character-based) results in unpredictable read-only Width values (points-based) due to font metrics, rounding, and internal units.
Before you start

Save a backup of your workbook containing the target layout, and ensure that the Developer tab is enabled to run VBA macros.

Solution 1Recommended

Use an Iterative VBA Macro to Match Width

Use a VBA script that increments the ColumnWidth in tiny steps until the read-only Width property reaches your desired point value.

Excel's ColumnWidth property is determined by the width of the '0' character in the normal font, whereas the Width property is a read-only measurement strictly in points.

Because of internal rounding and font rendering variations, a direct mathematical conversion formula is completely unreliable. The most effective workaround is an iterative scripting approach.

1
Open the VBA Editor

Press Alt + F11 on your keyboard to launch the Visual Basic for Applications editor in your spreadsheet.

2
Insert a New Module

Click on 'Insert' in the top menu bar, then select 'Module' to create a blank script window.

3
Add the Iterative Script

Write a loop that incrementally increases the target column's ColumnWidth by a small amount (e.g., 0.1) and continuously checks if the Range.Width matches or exceeds your desired points.

4
Run the Macro

Press F5 or click the Run button to execute the script and automatically adjust your column to the closest possible point width.

Use an Iterative VBA Macro to Match Width
Width Limitations: Excel imposes maximum column-width limits and internal rounding rules, meaning achieving exact point values down to the decimal may not always be mathematically possible.
Seamless VBA Support

Run Macro Scripts Easily with WPS Spreadsheet

WPS Office offers robust support for VBA macros, allowing you to use iterative scripts to precisely manage column widths. Enjoy the same advanced developer features in a lighter, faster application.

  1. 1. Open your file in WPS Spreadsheet: Launch WPS Office and open your .xlsm or .xlsx workbook.
  2. 2. Access Developer Tools: Navigate to the Developer tab on the top ribbon and click on the Visual Basic icon.
  3. 3. Apply your Column Width Macro: Paste your iterative VBA script into a new module to perfectly align your column widths, then press Run.
Fully compatible with Microsoft Excel (.xlsx and .xlsm) formatsSupports advanced VBA macros for precise layout controlLightweight, fast, and offers a highly familiar user interface
microsoft office alternative - wps office

Frequently Asked Questions

Why is the Excel ColumnWidth property measured in characters?

Excel historically designed column widths to fit a specific number of characters of the default system font (specifically the '0' character) to make standard data entry and reading more predictable.

Can I change Excel's column width unit to inches or centimeters?

In the Normal view, the unit remains in characters. However, if you switch to the Page Layout view via the View tab, you can adjust column widths using inches or centimeters via the ruler or the Column Width dialog box.

What is the maximum column width I can set?

The maximum ColumnWidth limit in Excel is 255 characters. If your iterative VBA script tries to exceed this threshold, it will trigger an error and halt execution.