NOVELTY - Producing hydrocarbons from biomass, comprises e.g. (i) supplying a starting stream (1) comprising hydrogen, carbon monoxide and other gases from biomass gasification or other synthesis gas production method to a first membrane step comprising water vapor selective and carbon dioxide-selective membrane, and separating through at least a part of water vapor present in the starting stream and a part of carbon dioxide present in the starting stream for the formation of water vapor and carbon dioxide containing permeate stream (3) and hydrogen and carbon monoxide containing retentate stream.    USE - The method is useful for producing hydrocarbons from biomass.    DETAILED DESCRIPTION - Producing hydrocarbons from biomass, comprises (i) initially supplying a starting stream (1) comprising hydrogen, carbon monoxide and other gases from the biomass gasification or other synthesis gas production method to a first membrane step comprising water vapor selective and carbon dioxide-selective membrane and separating through at least a part of water vapor present in the starting stream and a part of carbon dioxide present in the starting stream for the formation of water vapor and carbon dioxide containing permeate stream (3) of the first membrane step, and hydrogen and carbon monoxide containing retentate stream of the first membrane step, (ii) supplying the retentate stream of the first membrane step to a Fischer-Tropsch reactor for producing a product stream (5) comprising hydrogen, water vapor, hydrocarbons and optionally other gases and/or vapors, supplying the product stream from the Fischer-Tropsch reactor to a second membrane step comprising hydrogen-selective and water vapor selective membrane, and separating through at least a part of hydrogen and water vapor present in the product stream of the Fischer-Tropsch reactor to form hydrogen and water vapor containing permeate stream (7) of the second membrane step and hydrocarbon containing retentate stream (6) of the second membrane step, (iii) mixing the permeate stream of the second membrane step with the retentate stream of the first membrane step, and supplying to the Fischer-Tropsch reactor, (iv) supplying the retentate stream of the second membrane step to a first separator step, separating the retentate stream of the second membrane step into a gas phase, a liquid fraction and optionally into further fractions, supplying the gas phase of the first separator step to a third membrane step comprising hydrogen-selective and water vapor selective membrane, and separating into at least one part of hydrogen in the gas phase of the first separator step from light gases to form hydrogen and water vapor containing permeate stream of the third membrane step and light gases containing retentate stream of the third membrane step, and (v) mixing the hydrogen containing permeate stream of the third membrane step with the retentate stream of the first membrane step and the permeate stream of the second membrane step for recycling into the Fischer-Tropsch reactor.    DESCRIPTION OF DRAWING(S) - The figure shows a schematic process flow of the method.    Starting stream (1)    Water vapor and carbon dioxide containing permeate stream (3)    Product stream (5)    Hydrocarbon containing retentate stream (6)    Hydrogen and water vapor containing permeate stream (7)