A finite element heterogeneous multiscale method is proposed for solving the Stokes problem in porous media. The method is based on the coupling of an effective Darcy equation on a macroscopic mesh with unknown permeabilities recovered from micro finite element calculations for Stokes problems on sampling domains centered at quadrature points in each macro element. The numerical method accounts for nonperiodic microscopic geometry that can be obtained from a smooth deformation of a reference pore sampling domain. The computational work is nevertheless independent of the small size of the pore structure. A priori error estimates reveal that the overall accuracy of the numerical scheme is limited by the regularity of the solutions of the Stokes microproblems. This regularity is low for a typical situation of nonconvex microscopic pore geometries. We therefore propose an adaptive scheme with micro- macro mesh refinement driven by residual-based indicators that quantify both the macro- and microerrors. A posteriori error analysis is derived for the new method. Two- and three-dimensional numerical experiments confirm the robustness and the accuracy of the adaptive method.