A ship's propeller counter became a saloon's cash register

James Ritty ran a saloon in Dayton, Ohio, and suspected his staff were pocketing customers' money.
In 1871 James Ritty opened a saloon in Dayton, Ohio, advertising himself as a "Dealer in Pure Whiskies, Fine Wines, and Cigars." He came to believe that some of his employees were keeping money that customers paid for food and drink.
In 1878 he took a steamboat trip to Europe. On board he became interested in a mechanism that counted how many times the ship's propeller went around. He wondered whether something like it could keep count of the money taken at his bar.
Back in Dayton he and his brother John, a skilled mechanic, started work on a machine. Several prototypes failed. The third design worked. Each key stood for an amount of money, and pressing it added that amount to a running total shown on a dial with two hands, one for dollars and one for cents. There was no cash drawer and no receipt. At closing time the owner compared the total on the dial with the money in the till, allowing for what had been there the night before, and could tell whether any cash was missing.
The cash register was invented to stop what?
WhySaloon owner James Ritty patented it in 1879 because he believed his bartenders were pocketing cash. His machine rang a bell and showed each sale on a dial, so the day's takings could be checked against the till.
The brothers patented the machine on November 4, 1879. The patent itself calls it an "Improvement in cash register and indicator," so theirs was not the first. They opened a small factory in Dayton and kept the saloon going. One later model was sold as "Ritty's Incorruptible Cashier."
The factory did not do well, and running two businesses was too much for Ritty. In 1881 he sold his interest in the cash register business. In 1884 John H. Patterson, who had been in the coal business, took control of the company and renamed it the National Cash Register Company. Patterson added a roll of paper that recorded each sale. That gave the business a written record and the customer a receipt, and the first purpose of the receipt was the same as Ritty's dial: to stop cashiers from stealing.
Ritty did not resent missing out. He stayed on friendly terms with Patterson and was often invited to the company's meetings. In 1882 he opened another saloon, the Pony House, with a carved mahogany bar 12 feet tall and 32 feet wide. He retired from the bar business in 1895. When the Pony House building was torn down in 1967, the bar was saved.