According to the critical brain hypothesis, the brain is considered to operate near criticality and realize efficient neural computations. Despite the prior theoretical and empirical evidence in favor of the hypothesis, no direct link has been provided between human cognitive performance and the neural criticality. Here we provide such a key link by analyzing resting-state dynamics of functional magnetic resonance imaging (fMRI) networks at a whole-brain level. We develop a data-driven analysis method, inspired from statistical physics theory of spin systems, to map out the whole-brain neural dynamics onto a phase diagram. Using this tool, we show evidence that neural dynamics of human participants with higher fluid intelligence quotient scores are closer to a critical state, i.e., the boundary between the paramagnetic phase and the spin-glass (SG) phase. The present results are consistent with the notion of “edge-of-chaos” neural computation.