Limited borrower information may create targeting distortions in credit markets. Community-based lending programs may reduce these distortions by exploiting information transmitted in local networks, but connections may create asymmetries in power. This paper analyzes how local leaders balance issues of neediness, productivity (TFP), risk, and favoritism to allocate subsidized loans to Thai villagers. Local leaders provided credit to richer, less-productive and elite-connected villagers. These connection-based distortions threatened the program's sustainability. Moreover, eliminating these distortions would increase village-level output by 1.5%. Finally, informal markets partially attenuated the targeting distortions by redirecting credit to unconnected households, albeit at high interest rates.