A process and system for converting a carbonaceous feedstock into a product gas (which preferably comprises methane and at least one hydrocarbon having a carbon number of at least two, e.g. tar), where the process comprises the steps of: i) pyrolysing and methanating the feedstock to produce a reaction gas in at least one reaction chamber, wherein the at least one reaction chamber comprises at least one inlet and at least one outlet, ii) removing the reaction gas from at least one of the at least one outlet of the at least one reaction chamber, iii) separating the reaction gas into a product gas portion and a portion for further processing, iv) circulating the portion for further processing into at least one of the at least one inlet of the at least one reaction chamber for further processing, v) recovering the product gas portion.