The invention discloses a fundus image blood vessel segmentation method based on skeleton prior and contrast loss. The fundus image blood vessel segmentation method comprises the following steps: S1, performing data augmentation on a color fundus image; s2, performing expert annotation on the eye fundus image to extract a skeleton; s3, inputting the eye fundus image into a segmentation network, and calculating segmentation loss; s4, the foreground and background features of the middle features are compared to learn loss; s5, outputting a skeleton continuity constraint for the segmentation model, and solving a loss function; s6, superposing the three loss functions to obtain total loss, carrying out gradient back propagation, and stopping training when the total loss is not reduced any more for four consecutive rounds; and S7, obtaining a binary vascular tree segmentation result. Compared with the prior art, the contrast loss function adopted in the two types of pixel feature sample sets can further improve the discrimination capability of the model for hidden layer features in a high-dimensional space, can extract small blood vessels and prevent the blood vessels from being broken, can inhibit the interference of biomarkers, and is very suitable for fine retinal vessel tree segmentation.