A process for thermally converting methane into hydrocarbons with higher molecular weights in a ceramic reaction zone having an axis and provided with parallel rows of channels extending over at least a part of the total reaction zone said channels being lengthwise parallel to said axis and to each other, said rows of channels being spaced from one another, the reaction zone also comprising a heating zone in indirect heat exchange contact with said rows of channels and a cooling zone which is an extension of said heating zone and is in indirect heat exchange contact with said rows of channels, comprising circulating a gas containing methane in the channels of said rows, heating the heating zone with an electric power supply through successive, independent transverse sections which are substantially perpendicular to the axis of said reaction zone and in indirect heat exchange contact with the channels of the reaction zone, so that a first part of the heating zone is maintained at a maximum temperature above 650.degree. C. to at most 1,500.degree. C., at a temperature gradient ranging from 5.degree. C./cm to 60.degree. C./cm on a length from 5 to 50% of the total heating zone length, and wherein a second part of the heating zone, following said first part is heated at substantially said maximum temperature so that the temperature variation all along said second part is less than about 20.degree. C., and said circulated gas is heated to the maximum temperature introducing a cooling fluid into said cooling zone and collecting said hydrocarbons with higher molecular weights at the end of the reaction zone.