U-87 may refer to one of the following German submarines:

, a Type U 87 submarine launched in 1916 and that served in the First World War until sunk on 25 December 1917 During the First World War, Germany also had this submarine with a similar name: , a Type UB III submarine launched in 1917 and surrendered on 20 November 1918; broken up at Brest in 1921 , a Type VIIB submarine that served in the Second World War until sunk on 4 March 1943