The first European known to reach New Zealand was the Dutch explorer Abel Tasman, who arrived with his ships "Heemskerck" and "Zeehaen" in 1642. Over 100 years later, in 1769, the British naval captain James Cook of HM Bark "Endeavour" made the first of his three visits. From the late 18th century, the country was increasingly visited by British, French and American whaling, sealing and trading ships. In 1841 New Zealand became a British colony followed by a period of wars. New Zealand gradually became more self-governing and achieved the relative independence of a dominion in 1907.