How to Display a Stacked Fraction in Excel While Keeping the Value as 0.5
Question details
The user wants to visually display a vertically stacked fraction (such as 1/2) in a spreadsheet cell without losing its actual numeric decimal value (0.5), ensuring the data can still be used in mathematical calculations.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- Formatting financial, mathematical, or engineering data where a vertical fractional representation is preferred for document readability, but standard decimal values are strictly required for ongoing formulas.
- Observed behavior
- Standard fraction typing often converts to dates or text, and Excel's default fraction formatting only displays fractions side-by-side (1/2) rather than visually stacked on top of one another.
Before altering your cell layouts, ensure your source data is securely stored as numeric decimal values (like 0.5) so that visual formatting adjustments do not disrupt your existing spreadsheet calculations.
Use an Auxiliary Column with In-Cell Visual Stacking
Create a dedicated display cell using a line break and underlining to simulate a stacked fraction while keeping the original decimal value safe in another cell for calculations.
Since standard number formatting only supports side-by-side fractions, this manual workaround creates the visual appearance of a stacked fraction directly inside a cell. It is best to maintain an auxiliary column so your core data remains purely numeric.
Keep your original numeric value (e.g., 0.5) in a designated calculation column. You can hide this column later if you only want to see the fractions.
In a new adjacent cell, type the number '1', press 'Alt + Enter' to insert an in-cell line break, and then type the number '2'.
Highlight only the '1' in the formula bar at the top of the screen, and click the 'Underline' button (or press Ctrl + U) to create the fraction's dividing line.
Select the cell, adjust the row height to fit both numbers, and apply 'Center' alignment both horizontally and vertically to complete the stacked appearance.

Insert an Equation Object for a True Stacked Fraction
Use the built-in Equation tool to insert a perfectly formatted, vertically stacked fraction as a floating graphical object over your worksheet.
Apply Standard Fraction Formatting
If vertical stacking is not strictly mandatory, use Excel's standard fraction formatting to easily display 0.5 as a side-by-side 1/2 while keeping the cell completely numeric.
Format Fractions and Equations Seamlessly in WPS Spreadsheet
WPS Office provides robust cell formatting capabilities and an advanced Equation Editor, allowing you to display fractions exactly how you need them—whether standard or visually stacked—while fully preserving your underlying calculation data.
- 1. Open your workbook in WPS Spreadsheet: Launch WPS Office and open your spreadsheet document containing the decimal values.
- 2. Apply standard fraction formats: Select the cell containing your decimal, right-click to select 'Format Cells', navigate to the 'Number' tab, and choose 'Fraction' to automatically convert 0.5 to 1/2.
- 3. Insert custom stacked fractions: If a vertical stack is required, go to the 'Insert' tab and click 'Equation' to build a custom floating stacked fraction over your numeric data cells.

Frequently Asked Questions
Why does my spreadsheet change my fraction into a date?
When you type a fraction like '1/2' directly into a cell without any prior formatting, the software often misinterprets it as a date (January 2). To prevent this, type a zero followed by a space before the fraction (e.g., '0 1/2'), which forces the cell to recognize it as a numeric fraction.
Can I use a vertically stacked equation object in my formulas?
No. Equation objects are floating graphical elements intended for visual presentation only. They do not hold intrinsic cell values. To perform calculations, you must maintain the actual numeric decimal value (like 0.5) in a standard worksheet cell.
Is there a custom number format code to display fractions vertically?
No, standard custom number format codes (such as '# ?/?') only support rendering fractions in a linear, side-by-side format. True vertical stacking requires using a floating equation object or manually structuring a text cell with line breaks and underlining.




