We consider a thin film of a power-law fluid flowing over an undulated substrate under the action of gravity. Instead of determining the free surface position as in the case of a direct problem, we focus on the inverse problem, where for a specific free surface shape, we find the corresponding bottom topography which causes the free surface profile. As an asymptotic approach for thin films and moderate Reynolds numbers, we apply the weighted-residual integral boundary-layer method (WRIBL) which enables us to derive a set of two evolution equations for the film thickness h and the flow rate q. We obtain the steady solutions of the above model equation for the inverse problem for weakly undulated free surface profile by a perturbation method. We examine the influence of viscosity of fluid, inertia, film thickness, hydrostatic pressure and surface tension on the reconstructed bottom topography for a shear-thinning fluid. For a moderately undulated free surface shape, we solve the model equation numerically and obtain the bottom topography. We perform spatial linear stability analysis of the corresponding direct problem using Floquet theory. The results show that the critical Reynolds number is influenced by the shear-thinning rheology, surface tension effects and the amplitude of the free surface of the target profile. The analysis provides a strategy for control of free surface instabilities that arise in gravity-driven shear-thinning films over inclined undulated substrates and it corresponds to reconstruction of bottom undulated substrate that causes a target free surface. © 2015 Elsevier B.V.