I know its kinda of a ridiculous question but my friends and I have been arguing about the question and I would love to know.
It depends on the situation, and the pirate in question. In short, the answer is almost always no. But sometimes.
We have to distinguish which pirates we're talking about first of all. The answer will be different for Grecco-Roman Pirates, Medieval Baltic pirates, Barbary Corsairs, and South China Sea pirates.
Let's narrow down our pirates to the European pirates operating in the Caribbean and Indian Ocean during the 17th and 18th Centuries. That's The Golden age of Piracy, and what most people mean when they talk about pirates.
Most pirates and seafaring people in the Age of Sail went barefoot when the weather allowed. It gives better grip on deck and when climbing the rigging, and bare feet dry out better than shoes when they get wet.
When they needed some protection, or were going ashore, pirates usually wore sandals. Early Buccaneers traded with the Miskito and Guna people on the Spanish Main for their sandals, which weren't manufactured in European ports. It was one of the traits that distinguished pirates and smugglers from more respectable sailors. It distinguished them as men that called in 'barbarous' lands.
Check out Howard Pyle's "The Buccaneer Was a Picturesque Fellow"
The image of sailors wearing polished buckled shoes and captains wearing high boots comes from two sources.
First, when a new ship was launched or a ship's captain was given honors, it would be often visited by significant dignitaries.
When James, Lord High Admiral and Duke of York (or Admiral Pepys) visited a new ship of the line the officers and petty officers would be present and in full dress. That included shoes for the petty officers and Naval boots for the Captain and Mates. Both would have been wearing stockings. That image informed later artists, but doesn't apply to pirates.
Queen Elizabeth I visited the Golden Hind upon her return to England, and Francis Drake was knighted by the French Ambassador. The crew wore their Sunday best, which would have been the height of Elizabethan fashion. That would include boots and hose. Hundreds of Londoners saw them wearing those clothes on board when Drake was knighted, and hundreds more toasted them in local pubs for weeks. Take a look at this bronze plaque from 1883.
Second, the popularity of Cavalier boots and Spanish Naval Boots.
Henry Morgan would have likely worn Cavalier Boots, which gained popularity during the English Civil War. They were made from soft leather and well oiled. They were designed for cavalry, hence the heel, but they gained popularity among the officer class in England. French, Spanish, & Dutch officers also had similar styles.
Boots like these stayed in fashion for sea officers for decades, and those officers would have worn hose or stockings underneath. They weren't fit for real work on board, but they looked quite dashing.
Any officers that wore these would have worn hose or stockings with them. But did pirates wear them? Not usually, but sometimes. Pirates usually wore very simple clothing of wool or linen or hemp. Leather pants or coats weren't unheard of. They were poor, and dressed accordingly.
But the captains would sometimes dress differently. When pirates took a prize, either at sea or on land, they often took clothes with them. Alexander Exquemelin, Bartholomew Sharp, and Raveneau de Lussan all mention pirates raiding the officers quarters for their clothing. There are Spanish records of pirates torturing captives while wearing full formal Spanish military dress. Pirate captains would often claim the best officer's clothes of any prize taken. That means they did have the plumed hats, fancy coats, high boots, and stockings.
They didn't always wear them, or even wear them often, but they did usually wear them to be seen. When your crew takes a prize and you need to go aboard to accept a surrender? Put on the fancy boots. When you visit Nassau or Tortuga and go ashore and will meet with other captains or crews? Put on your fancy boots.
At sea the crew would have been disgusted to see their captain wearing those boots and looking self important, but when the Captain needed to impress, he would wear his best.
And that included socks.