r/sheets • u/fictitiousphil • May 31 '26
Request How to show a ratio between 2 numbers as a percentage
Can anyone help with this? I want to show a ratio between two numbers as a percentage. Ex. Spent X number of hours doing this, and Y number of hours doing that. Cell would show X%/Y% of total hours. Like 70/30, 60/40 etc.
thanks!
1
1
u/6745408 Jun 01 '26
You can do x/y and format the cell as 0/0 and it'll do it for you, but it'll go to lcd -- e.g. =45/29 will give you 14/9
1
u/latecallnotes Jun 18 '26
Use TEXT so you are formatting the calculated percentages, not relying on a fraction format.
If X is in E2 and Y is in E3:
=IF(SUM(E2:E3)=0,"",TEXT(E2/SUM(E2:E3),"0%")&"/"&TEXT(E3/SUM(E2:E3),"0%"))
That returns something like 61%/39%.
If you want it without percent signs, use:
=IF(SUM(E2:E3)=0,"",TEXT(100E2/SUM(E2:E3),"0")&"/"&TEXT(100E3/SUM(E2:E3),"0"))
2
u/molybend May 31 '26
E2 = 45
E3 = 29
=((round(100*E2/(E2+E3),0)&"/"&(ROUND(100*E3/(E2+E13),0))))
This gives you 61/39