We find a nonsemisimple fusion algebra F_p associated with each (1,p) Virasoro model. We present a nonsemisimple generalization of the Verlinde formula which allows us to derive F_p from modular transformations of characters.