
Short answer Ketchup was first a word for pickled fish brine, and tomato ketchup came along in the 1800s.
Nothing goes with fries like ketchup. But ketchup didn't start out as a tomato sauce.

One explanation is that the word comes from the local language of Fujian, in southern China. It was the name for brine from pickled fish or shellfish.
Wait, ketchup was fish?
Old ketchup recipes used all kinds of things. There were ketchups made from mushrooms, oysters, mussels and walnuts.
1812the year of the first known tomato ketchup recipe
In 1812, James Mease of the US wrote down the first tomato ketchup recipe.
An 1817 tomato ketchup recipe even had anchovies and bugs used to make it red.
Ketchup with bugs in it is a bit much...
Sources
Photo credits
More useless facts
FoodBananas Are BerriesStrawberries aren't berries, but bananas are
PsychologyYour Dog Can Catch Your YawnsWhen you yawn, your dog might yawn right along with you
AnimalsKoala Fingerprints Can Pass for Human OnesEven under an electron microscope, koala and human fingerprints are hard to tell apart
GeographyIn Antarctica, Even the Time Zone Follows the Delivery GuyAt the very bottom of the Earth, the South Pole station's clocks are set to New Zealand time