At the request of the European Commission, EFSA prepared specific guidelines for the survey of Xylella fastidiosa to guide the survey or through the design of statistically sound and risk‐based surveys, integrating the key biological information. Based on examples, three different survey designs are simulated: detection surveys to substantiate pest freedom, delimiting surveys to determine the boundaries of an infested zone, and buffer zone surveys to monitor a zone ensuring pest detection at a low level of prevalence. The first step of the survey design consists of setting out the aims of the survey, characterising the host plant population and the methods used to identify the pest. All the survey parameters are quantified considering the importance of the related assumptions. The more accurate the information used to select/estimate the survey parameters, the more robust the conclusions of the survey will be. The second step of the survey design consists of the sample‐size calculation using the survey parameters as inputs forthe statistical tool (RiBESS+). The last step of the survey design is the allocation of the samples in the survey area, the method for which depends on the information available on the target population and risk factors. The robustness of the conclusions of surveys designed using these approaches depends strongly on the survey preparation. The methodology here proposed allows surveys to be compared across time and space, thus contributing to harmonisation of the X. fastidiosa surveys in the EU Member States. The extremely flexible approaches allow surveys to be tailored to each specific situation in the Member States, taking into account the host plants, vectors, climate suitability and resources available. The success of a good survey design relies on technical aspects of the survey preparation and on the involvement of the risk managers.