Despite the high resource potential of shale-gas reservoirs, the vast consumption of freshwater by hydraulic fracturing significantly increases the environmental footprint and results in generation of large volumes of hyper-saline wastewaters. Conventional membrane technologies such as reverse osmosis are incapable of treating such high salinity. Membrane distillation (MD), a hybrid approach of thermal distillation and membrane process using hydrophobic membranes, is an alternative technology. However, current MD technology cannot treat shale-gas wastewaters because of pore wetting of the membranes by organic contaminants. We find that the nanostructure architecture of MD membranes can significantly improve surface omniphobicity and subsequently wetting resistance. Specifically, nanofiber membranes grafted with nanoparticles possess multi-level re-entrant structures and exhibit excellent wetting resistance against water and organic liquids. We demonstrate the potential of omniphobic membranes to desalinate highly saline, low surface tension feedwater by MD and to treat various challenging industrial wastewaters.