The invention provides a preparation method of a SrAlB2O7:Eu<3+> fluorescent probe for detection of OPs (organophosphorus pesticides). The preparation method comprises two steps as follow: firstly, Eu<3+> and target analyte, OP molecules, interact to form organic ligand, then strontium nitrate, aluminum nitrate, boric acid and a pore-forming agent are added to a beaker accommodating deionized water, the mixture is stirred, and sol is formed; calcination is performed after gel is obtained, and Eu<3+> marked OP molecular printing SrAl2B2O7:Eu<3+> fluorescent probe is obtained. OP molecule selectivity recognition sites are available after template molecules are removed, the OP molecules further interact with Eu<3+> on the recognition sites after entering the recognition sites of the fluorescent probe, the OP molecules and the recognition sites form organic ligand, the organic ligand absorbs energy and transfers the energy to Eu<3+>, the fluorescence intensity of the fluorescent probe is changed, and selective recognition and detection of pesticide molecules are realized.