The Stirling Engine was a very efficient engine and less polluting, although less powerful, engine than the Otto Engine that was used in most cars in the late 1800s. Could the Stirling Engine have been used rather than the Otto Engine in cars?
Yes it could have. But it is a poor choice for a number of reason (mostly throttling problems) and it would make very poor cars given the early technology. Today it would be a potential option for a hybrid car, but otherwise it's best used for low-power, low-maintenance equipment.