The sub-ohmic spin-boson model is known to possess a novel quantum phase transition at zero temperature between a localised and delocalised phase. We present here an analytical theory based on a variational ansatz for the ground state, which describes a continuous localization transition with mean-field exponents for 0 < s < 0.5. Our results for the critical properties show good quantitiative agreement with previous numerical results, and we present a detailed description of all the spin observables as the system passes through the transition. Analysing the ansatz itself, we give an intuitive microscopic description of the transition in terms of the changing correlations between the system and bath, and show that it is always accompanied by a divergence of the lowfrequency boson occupations. The possible relevance of this divergence for some numerical approaches to this problem is discussed and illustrated by looking at the ground state obtained using density matrix renormalisation group methods.The physics of quantum systems in contact with environmental degrees of freedom plays a fundamental role in many areas of physics, chemsitry and biology, including systems as diverse as solid state quantum computers[1, 2], quantum impurities [3], and photosynthetic biomolecules [4][5][6][7][8]. A key theoretical model for the study of system-environment interactions is the spin-boson model (SBM), which consists of a two-level system (TLS) that is linearly coupled to an 'environment' of harmonic oscillators [9,10]. Although this model has been studied extensively, there are still many open problems in SBM physics, most notably those concerning the quantum phase transition (QPT) between delocalised and localised phases that exists in the SBM when the oscillators are characterised by sub-Ohmic spectral densities.The standard quantum-classical mapping predicts that the sub-ohmic SBM should be equivalent to a classical Ising spin chain with long-range interactions, and predicts a continuous magnetic transition with mean-field critical exponents for 0 < s < 0.5. In Ref.[11], a continuous transition in the sub-Ohmic SBM was observed using the numerical renormalisation group (NRG) technique for all values of 0 < s < 1, but the critical properties of the transition were found to be non-mean-field for 0 < s < 0.5. It was suggested that this implied a breakdown of the classical to quantum mapping, and some subsequent work in this and other systems has supported this claim [12,13]. However, it is now believed that the nonmean-field results found by NRG in 0 < s < 0.5 are incorrect, and arise from the truncation of the number of states N b used to describe each oscillator in the Wilson chain [14,15]. Recent studies of the sub-Ohmic QPT using quantum monte carlo (QMC) [16], sparse polynomial space approach (SPSA) [17], and an extended coherent state technique have indeed found mean-field critical exponents for 0 < s < 0.5 [18].In this article we propose a variational ansatz for the ground state of the sub-Ohmic SBM for 0 < s < 0.5 whi...