Both the imperial and United States customary systems of measurement derive from earlier English systems used in the Middle Ages, that were the result of a combination of the local Anglo-Saxon units inherited from German tribes and roman units brought by William the Conqueror after the Norman Conquest of England in 1066.
Having this shared heritage, the two systems are quite similar, but there are differences. The US customary system is based on English systems of the 18th century, while the Imperial system was defined in 1824, after American independence.
The imperial gallon was originally defined as the volume of 10 avoirdupois pounds of water under specified conditions. The imperial gallon (4.54609 litres (L)) is 20% larger than the United States liquid gallon (3.785411784 L). The imperial bushel (36.36872 L) is 8 imperial gallons and is about 3% larger than the US bushel (35.23907016688 L)
The subdivision of the imperial gallon in British apothecaries' fluid measure differed in two important respects from the corresponding United States subdivision:
the imperial gallon was divided into 160 fluid ounces, the United States gallon into 128 fluid ounces; and a "fluid scruple" is included.
https://en.wikipedia.org/wiki/Comparison_of_the_imperial_and_US_customary_measurement_systems