Google Sheets Cell Format – Format Cells to Show Only 3 Digits

google sheetsgoogle-sheets-cell-format

Is there any way to do this:

I have cell and most of the numbers have 2 significant digits like 3.45. But once in a while I have a number like 143 big number, the rest are under 10. Currently for 143 the cell is displaying 143.00 which takes up too much space. I want it to show 143 just three digits. Is there a way to format it so it only shows 3 digits? no matter where the decimal point is?

Best Answer

What you're looking for is conditional number formatting. You can do this in the Google doc by highlighting the column you wish to format and clicking:

Format → Number → More Formats → Custom number format...

Thereafter, specify this as your formula:

[<10]_(###0.00_);_(#0_)

What it means is, if the cell value is less than 10 then format the cell in #,##0.00 format otherwise format as #0.

You can read more info over here:

Display decimals only when the number is less than 1 [Excel number formatting tip]

As well as here:

Number Formats in Microsoft Excel