A process for preparing polyoxymethylene dimethyl ethers, comprising the following steps: - mixing of a stream S FA containing a water-containing formaldehyde source with a stream S OME1 containing methylal, to obtain a reactant mixture M Reactant, - reaction of the reactant mixture M Reactant in a reactor R1 to obtain a product mixture M R1 containing polyoxymethylene dimethyl ethers of the formulae H 3 C-O-(CH 2 O) 2 -CH 3, H 3 C-O-(CH 2 O) 3-5 -CH 3 and H 3 C-O-(CH 2 O) n -CH 3 with n ≥ 6 and also formaldehyde, methylal, methanol and water, - introduction of the product mixture M R1 into a distillation unit D1 and distillative separation of the product mixture M R1 into a first fraction which contains methylal, H 3 C-O-(CH 2 O) 2 -CH 3, formaldehyde, methanol and water and leaves the distillation unit D1 as top stream KS D1, and a second fraction which contains the polyoxymethylene dimethyl ethers of the formulae H 3 C-O-(CH 2 O) 3-5 -CH 3 and H 3 C-O-(CH 2 O) n -CH 3 with n ≥ 6 and leaves the distillation unit D1 as bottom stream SS D1, - mixing of the top stream KS D1 with a methanol-containing stream S MeOH to obtain a mixture M1, - reaction of the mixture M1 in at least one reaction zone RZ of a reactive distillation unit RD2 in the presence of an acid catalyst, wherein H 3 C-O-(CH 2 O) 2 -CH 3 reacts to give methylal and formaldehyde, and formaldehyde and methanol react to give methylal; and distillative separation into a first fraction which contains methylal (OME 1) and leaves the reactive distillation unit RD2 as top stream KS RD2, and a second fraction which contains water and leaves the reactive distillation unit RD2 as bottom stream SS RD2, - introduction of the bottom stream SS D1 into a distillation unit D3 and distillative separation of the polyoxymethylene dimethyl ethers of the formulae H 3 C-O-(CH 2 O) 3-5 -CH 3 and H 3 C-O-(CH 2 O) n -CH 3 with n ≥ 6 present in the bottom stream SS D1 into a fraction which leaves the distillation unit D3 as top stream KS D3, and a fraction which leaves the distillation unit as bottom stream SS D3. - mixing of a stream S FA containing a water-containing formaldehyde source with a stream S OME1 containing methylal, to obtain a reactant mixture M Reactant, - reaction of the reactant mixture M Reactant in a reactor R1 to obtain a product mixture M R1 containing polyoxymethylene dimethyl ethers of the formulae H 3 C-O-(CH 2 O) 2 -CH 3, H 3 C-O-(CH 2 O) 3-5 -CH 3 and H 3 C-O-(CH 2 O) n -CH 3 with n ≥ 6 and also formaldehyde, methylal, methanol and water, - introduction of the product mixture M R1 into a distillation unit D1 and distillative separation of the product mixture M R1 into a first fraction which contains methylal, H 3 C-O-(CH 2 O) 2 -CH 3, formaldehyde, methanol and water and leaves the distillation unit D1 as top stream KS D1, and a second fraction which contains the polyoxymethylene dimethyl ethers of the formulae H 3 C-O-(CH 2 O) 3-5 -CH 3 and H 3 C-O-(CH 2 O) n -CH 3 with n ≥ 6 and leaves the distillation unit D1 as bottom stream SS D1, - mixing of the top stream KS D1 with a methanol-containing stream S MeOH to obtain a mixture M1, - reaction of the mixture M1 in at least one reaction zone RZ of a reactive distillation unit RD2 in the presence of an acid catalyst, wherein H 3 C-O-(CH 2 O) 2 -CH 3 reacts to give methylal and formaldehyde, and formaldehyde and methanol react to give methylal; and distillative separation into a first fraction which contains methylal (OME 1) and leaves the reactive distillation unit RD2 as top stream KS RD2, and a second fraction which contains water and leaves the reactive distillation unit RD2 as bottom stream SS RD2, - introduction of the bottom stream SS D1 into a distillation unit D3 and distillative separation of the polyoxymethylene dimethyl ethers of the formulae H 3 C-O-(CH 2 O) 3-5 -CH 3 and H 3 C-O-(CH 2 O) n -CH 3 with n ≥ 6 present in the bottom stream SS D1 into a fraction which leaves the distillation unit D3 as top stream KS D3, and a fraction which leaves the distillation unit as bottom stream SS D3.