We present an evaluation of heavy quarkonium states bbBAR, ccBAR from first principles. We use tree-level QCD (including relativistic corrections) and the full one-loop potential; nonperturbative effects are taken into account at the leading order through the contribution of the gluon condensate [alpha(s)G2]. We use the values LAMBDA(2 loops, 4 flavors) = 200(-60)+80 MeV, [alpha(s)G2] = 0.042 +/- 0.020 GeV4, but we trade the value of the quark mass with the masses of J/psi, UPSILON as input. We get good agreement in what is essentially a zero parameter evaluation for the masses of the 1S, 2S, 2P states of bbBAR, the 1S state for ccBAR, and the decay UPSILON --> e+e-. As outstanding results we obtain the precise determination of m(b) as well as an estimate of the hyperfine splitting M(UPSILON) - M(eta(b)): m(b)BAR(m(b)2BAR) = 4397(-2)+7 (LAMBDA)+4(-3) ([alpha(s)G2])-32(+16) (syst) MeV, M(UPSILON) -M(eta(b)) = 36(-7)+13 (LAMBDA)-6(+3) ([alpha(s)G2])-5(+11) (syst) MeV, the first error due to that in LAMBDA, the second to that in [alpha(s)G2]) (varied independently). For the c quark, we find m(c)BAR (m(c)2BAR) = 1306(-34)+21 (LAMBDA)+6(-6) ([alpha(s)G2]) MeV (up to systematic errors). The MSBAR b, c masses correspond to pole mass values of m(b)(pole) = 4906(-51)+69 (LAMBDA)+4(-4) ([alpha(s)G2])-40(+11) (syst) MeV and m(c)(pole) = 1570(-19)+19 (LAMBDA)-7(+7) ([alpha(s)G2]) MeV.