I'm not a super duper historian or anything but I love cars, and have read a lot of books on them.
In 1894, there was a concourse style running of cars from Paris to Rouen, but the cars weren't strictly judged on their speed, so many people kind of dismiss this as an official "race." It was more of a "show off your tech" cruise.
The first "official" car race according to most things I've read is the 1895 race from Paris to Bordeaux (and back) won by Emile Levassor in a car powered by a Gottlieb Daimler 2-cylinder. He averaged about 24mph and beat out multiple other cars. Considering the car was basically just invented 6-7 years prior, depending on what you consider a "car", that's pretty cool to get many cars together for a race.
The race actually took place this week in June, so good timing on your question.
Interestingly, Levassor was disqualified after finishing for having too few seats in his car. First place award went to a car he beat by almost 12 hours made by Peugeot (who made bikes before cars).
A few months later, the Chicago Times-Herald hosted a race on Thanksgiving Day that is credited with sparking the American love affair with cars. It was won by Frank Duryea, brother of the first American car builder, Charles Duryea.
In 1906 the first French Grand Prix happened, which became the forerunner of Formula One. The last year it was held was 2008.
The Indianapolis 500 is one of the oldest current races, starting in 1911.
One reference I've used is "The Automobile in American History and Culture" by Michael Berger. I also like, "Car: The definitive visual history of the Automobile," by Giles Chapman.
Road and Track Magazine did a pretty cool story on some super early races a few years back. I will check and see if I can find the issue when I get home. If you like cars, R&T and it's street cousin Car And Driver are two of the best to read.
Can't remember who said, but someone said auto racing has been in existence since the second car was made.