Scale up techniques are commonly used to coarsen detailed geological models to the scales more appropriate for reservoir simulation. These techniques typically generate upscaled permeabilities through the solution of the local pressure equation subject to some type of linear boundary condition. In the near-well region, coarse scale permeabilities computed in this manner may not adequately capture key features of the fine scale flow. In this paper, we present a general method for computing accurate coarse scale well block transmissibilities and well indexes for vertical wells in two and three dimensions. The method is based on the solution of local well-driven flow problems subject to generic boundary conditions. Simulation results for two dimensional systems indicate that the near-well treatment always provides improved predictions relative to those obtained using standard methods. In some parameter ranges, this improvement is quite substantial. Several three dimensional models are also considered and improvement relative to the standard approach is achieved in all cases. Extension of the method to accommodate complex well configurations could result in significantly improved coarse scale simulations of nonconventional wells.