The whaling ship in "Moby Dick" was named the Pequod. The Pequod is a worn, 19th-century Nantucket whaling ship. Most Nantucket whaling ships at the time were three-masted like the Pequod. However, all three masts on the Pequod were replacements, as the originals were lost in a typhoon in Japan.
The Pequod ship was based off of the Essex, a real whaling ship that sank in 1820. The author of "Moby Dick," Herman Melville, was 1 year old when the Essex sank. He heard the story of the Essex when he was older. The ship was torn to pieces by a whale, like the Peqoud was in "Moby Dick."