Commonly, the confinement effects are studied from the grand canonical Monte Carlo (GCMC) simulations from the computation of the density of liquid in the confined phase. The GCMC modeling and chemical potential (μ) calculations are based on the insertion/deletion of the real and ghost particle, respectively. At high density, i.e., at high pressure or low temperature, the insertions fail from the Widom insertions while the performing methods as expanded method or perturbation approach are not efficient to treat the large and complex molecules. To overcome this problem we use a simple and efficient method to compute the liquid's density in the confined medium. This method does not require the precalculation of μ and is an alternative to the GCMC simulations. From the isothermal-isosurface-isobaric statistical ensemble we consider the explicit framework/liquid external interface to model an explicit liquid's reservoir. In this procedure only the liquid molecules undergo the volume changes while the volume of the framework is kept constant. Therefore, this method is described in the Np(n)AV(f)T statistical ensemble, where N is the number of particles, p(n) is the normal pressure, V(f) is the volume of framework, A is the surface of the solid/fluid interface, and T is the temperature. This approach is applied and validated from the computation of the density of the methanol and water confined in the mesoporous cylindrical silica nanopores and the MIL-53(Cr) metal organic framework type, respectively.