German submarine U-1227

German submarine U-1227 was a Type IXC/40 U-boat of the German Kriegsmarine during World War II.

The submarine was laid down on 1 February 1942 at the Deutsche Werft yard at Hamburg, launched on 18 September 1943, and commissioned on 8 December 1943 under the command of Oberleutnant zur See Friedrich Altmeier. The U-boat then served with 31st U-boat Flotilla, a training unit, with 2nd U-boat flotilla from 1 August 1944 to 31 December 1944, and with 33rd U-boat Flotilla from 1 January 1945 to 10 April 1945.

Service history
U-1227 completed only one combat patrol, from 14 September to 26 December 1944. On 4 October 1944 she attempted to attack a convoy at night, but was seen in the bright moonlight and counter-attacked by convoy escorts. She torpedoed one of the escorts, the Canadian River class frigate HMCS Chebogue (K317), during the pursuit. The frigate was a total loss, but the U-boat escaped and continued its patrol.

U-1227 was damaged at Kiel in a British night-bombing raid on 9 April 1945, and was decommissioned there on 10 April. U-1227 was scuttled to avoid capture on 3 May 1945.