You need to know the person's height, weight, and the formula to calculate
BMI= kg/m^2
Your weight has to be in kilos
However, this isn't always accurate because a person can be all muscle and their BMI might consider them overweight. When in reality they aren't.