Suppose the ground field to be algebraically closed and of characteristic different from 2 and 3. All Heisenberg Lie superalgebras consist of two super-versions of the Heisenberg Lie algebras, h(2m),(n) and ban with m a non-negative integer and n a positive integer. The space of a "classical" Heisenberg Lie superalgebra h(2m,n) is the direct sum of a superspace with a non-degenerate anti-supersymmetric even bilinear form and a one-dimensional space of values of this form constituting the even center. The other super-analog of the Heisenberg Lie algebra, ba(n), is constructed by means of a non-degenerate anti-supersymmetric odd bilinear form with values in the one-dimensional odd center. In this paper, we study the cohomology of h(2m,n) and ba(n) with coefficients in the trivial module by using the Hochschild-Serre spectral sequences relative to a suitable ideal. In the characteristic zero case, for any Heisenberg Lie superalgebra, we determine completely the Betti numbers and associative superalgebra structures for their cohomology. In the characteristic p > 3 case, we determine the associative superalgebra structure for the divided power cohomology of ba(n) and we also make an attempt to determine the divided power cohomology of h(2m,n) by computing it in a low-dimensional case. Published by AIP Publishing.