A method of removing gas from a gas producing subterranean formation and removing contaminants from resulting produced water, comprising: providing a mixture of gas and water gathered from the gas producing subterranean formation; separating the gas from the mixture to produce a gas product and the produced water which contains contaminants including organics, suspended solids, and dissolved solids including silica; removing suspended solids from the produced water; after removing at least some suspended solids from the produced water, directing the produced water to a macro porous polymer extraction (MPPE) unit, said MPPE unit including a column having an array of beads that comprise a polymer that encases or holds an extraction fluid; treating the produced water in the MPPE unit by removing aromatic organic compounds from the produced water; after treating the produced water in the MPPE unit, directing the produced water to a membrane bioreactor (MBR); treating the produced water in the MBR to remove additional organics; mixing a silica precipitation inhibiting agent with the produced water; after the silica precipitation inhibiting agent has been mixed with the produced water, directing the produced water to at least one RO unit and producing a high dissolved solids containing reject stream and a low dissolved solids permeate stream; and sufficiently removing contaminants from the produced water such that the permeate stream is suitable for: 1. use in a frac fluid; 2. use in drilling mud; or 3. discharge to the environment when the total dissolved solids are reduced to less than 1,000 ppm and substantially all of the organics are removed. providing a mixture of gas and water gathered from the gas producing subterranean formation; separating the gas from the mixture to produce a gas product and the produced water which contains contaminants including organics, suspended solids, and dissolved solids including silica; removing suspended solids from the produced water; after removing at least some suspended solids from the produced water, directing the produced water to a macro porous polymer extraction (MPPE) unit, said MPPE unit including a column having an array of beads that comprise a polymer that encases or holds an extraction fluid; treating the produced water in the MPPE unit by removing aromatic organic compounds from the produced water; after treating the produced water in the MPPE unit, directing the produced water to a membrane bioreactor (MBR); treating the produced water in the MBR to remove additional organics; mixing a silica precipitation inhibiting agent with the produced water; after the silica precipitation inhibiting agent has been mixed with the produced water, directing the produced water to at least one RO unit and producing a high dissolved solids containing reject stream and a low dissolved solids permeate stream; and sufficiently removing contaminants from the produced water such that the permeate stream is suitable for: 1. use in a frac fluid; 2. use in drilling mud; or 3. discharge to the environment when the total dissolved solids are reduced to less than 1,000 ppm and substantially all of the organics are removed. 1. use in a frac fluid; 2. use in drilling mud; or 3. discharge to the environment when the total dissolved solids are reduced to less than 1,000 ppm and substantially all of the organics are removed. <EOS>