The invention discloses a preparation method of pentaerythritol and dipentaerythritol, which comprises the following steps of: S1, heating formaldehyde to a set temperature by taking a formaldehyde aqueous solution as bottom water, adding an alkali solution and an acetaldehyde aqueous solution into the bottom water, and carrying out condensation reaction at a constant temperature; S2, adding a formic acid aqueous solution into the bottom water to stop the reaction to obtain a condensation solution containing pentaerythritol, dipentaerythritol and formate; S3, carrying out multistage evaporation and crystallization, and respectively collecting excessive formaldehyde, pentaerythritol, dipentaerythritol and formate from the condensation solution to obtain the pentaerythritol and the dipentaerythritol, wherein the molar ratio of the formaldehyde to the acetaldehyde is (4-10):1, the molar ratio of the alkali to the acetaldehyde is (1-2):1. According to the invention, the condensation reaction is carried out under the condition of constant temperature, the raw materials are easy to obtain, the control is simple, the product yield is high, and the product purity is high.