We present a new method to extract cosmological constraints from weak lensing ( WL ) peak counts , which we denote as ‘ the hierarchical algorithm ’ . The idea of this method is to combine information from WL maps sequentially smoothed with a series of filters of different size , from the largest down to the smallest , thus increasing the cosmological sensitivity of the resulting peak function . We compare the cosmological constraints resulting from the peak abundance measured in this way and the abundance obtained by using a filter of fixed size , which is the standard practice in WL peak studies . For this purpose , we employ a large set of WL maps generated by ray-tracing through N -body simulations , and the Fisher matrix formalism . We find that if low- { \mathcal { S } } / { \mathcal { N } } peaks are included in the analysis ( { \mathcal { S } } / { \mathcal { N } } \sim 3 ) , the hierarchical method yields constraints significantly better than the single-sized filtering . For a large future survey such as \mathit { Euclid } or \mathrm { LSST } , combined with information from a CMB experiment like \mathit { Planck } , the results for the hierarchical ( single-sized ) method are : \Delta { n _ { s } } = 0.0039 ( 0.004 ) ; \Delta { \Omega _ { m } } = 0.002 ( 0.0045 ) ; % \Delta { \sigma _ { 8 } } = 0.003 ( 0.006 ) ; \Delta w = 0.019 ( 0.0525 ) . This forecast is conservative , as we assume no knowledge of the redshifts of the lenses , and consider a single broad bin for the redshifts of the sources . If only peaks with { \mathcal { S } } / { \mathcal { N } } \geq 6 are considered , then there is little difference between the results of the two methods . We also examine the statistical properties of the hierarchical peak function : Its covariance matrix has off-diagonal terms for bins with { \mathcal { S } } / { \mathcal { N } } \leq 6 and aperture mass of M < 3 \times 10 ^ { 14 } h ^ { -1 } M _ { \odot } , the higher bins being largely uncorrelated and therefore well described by a Poisson distribution .