Abstract. In this paper we propose an analytical model for file diffusion in a peer-to-peer (P2P) file-sharing network based on biological epidemics. During the downloading process, the peer shares the downloaded parts of the file and, thus, contributes to distributing it in the network. This behavior is similar to the spreading of epidemic diseases which is a well researched subject in mathematical biology. Unlike other P2P models based on epidemics, we show that steady state assumptions are not sufficient and that the granularity of the diffusion model may be appropriately selected.