Optimal routing of a path with a constant width in a two‐dimensional grid of cost‐weighted square cells or pixels is a recent extension of the least‐cost path problem, and models and solutions are available and ready to be integrated into raster‐based geographic information systems. In this article we consider yet another variation of this problem in a three‐dimensional grid of cost‐weighted cubic cells or voxels, which is to find a tubular region of voxels with a constant width, referred to here as “corridor,” connecting two termini while accumulating the least amount of cost. We model a corridor as a sequence of sets of voxels, called “neighborhoods,” that are arranged in a 26‐hedral form, design a heuristic method to find a sequence of such neighborhoods that sweeps the minimum cost‐weighted volume, and test its performance with computer‐generated random data. Results show that the method finds a low‐cost, if not least‐cost, corridor with a specified width in a three‐dimensional cost grid and has a reasonable efficiency as its complexity is O(n2), where n is the number of voxels in the input cost grid and is independent of corridor width. A major drawback is that the corridor found may self‐intersect, which often not only is an undesirable quality but also makes the estimation of its cost‐weighted volume inaccurate.