The present invention relates to processes for preparing 7H-pyrrolo[2,3-d]pyrimidine derivatives which are useful as a Janus kinase (JAK) inhibitor, co-crystals thereof, processes for preparing the co-crystals, and processes for purifying 7H-pyrrolo[2,3-d]pyrimidine derivatives by employing the co-crystals. The present invention provides, for example, a process for preparing 3-[(3S,4R)-3-methyl-6-(7H-pyrrolo[2,3-d]pyrimidin-4-yl)-1,6-diazaspiro[3.4]octan-1-yl]-3-oxopropanenitrile by employing a co-crystal of 3-[(3S,4R)-3-methyl-6-(7H-pyrrolo[2,3-d]pyrimidin-4-yl)-1,6-diazaspiro[3.4]octan-1-yl]-3-oxopropanenitrile with 3,5-dimethylpyrazole.