The invention discloses a template-based document generation method and device, a storage medium and an apparatus. The method comprises the steps of generating a preset document template of each business scene and storing the preset document template to a server; Extracting a target document template from the server according to a template acquisition instruction input by a user; Obtaining a target variable, and positioning a target placeholder corresponding to the target variable in the target document template; Judging whether the number of the target variables is consistent with that of thetarget placeholders or not; And if yes, interpolating the target variable to the corresponding target placeholder to generate a target business document. According to the invention, Before the targetvariable is interpolated to the corresponding target placeholder, whether the number of the target variable is consistent with that of the target placeholders or not is judged, if yes, interpolationis carried out, it is guaranteed that the target placeholders are filled with the target variable, the interpolation process is more accurate, and therefore generation of the target business documentis more accurate, and errors are fewer.