The hamburger's ancestry begins with the "Hamburg steak," a dish of seasoned minced beef popular among German port workers and sailors in Hamburg during the 1700s and 1800s. German immigrants carried the recipe to American cities, where New York restaurants began serving it under its original name. By 1873, Delmonico's had the dish on its menu, though the patty was plated, not sandwiched.
The leap from plated steak to handheld sandwich happened around the turn of the twentieth century. Multiple claimants compete for credit, but Louis Lassen's story at Louis' Lunch in New Haven, Connecticut, is among the best documented: in 1900, he pressed ground steak trimmings between slices of toasted bread for a customer in a hurry. The restaurant still operates today using the same cast-iron vertical broilers manufactured in 1898.