 UB-42 was laid down on 3 September 1915. As one of six U-boats selected for service in the Mediterranean while under construction, UB-42 was broken into railcar-sized components and shipped overland to the Austro-Hungarian port of Pola. Shipyard workers from Weser assembled the boat and her five sisters at Pola, where she was launched on 4 March 1916.
