People often ask this question. The answer is that we don’t know for certain, but paleontologists can make some educated guesses.
Bones and teeth preserve under different conditions than tracks do. A bone or tooth needs to be covered fairly quickly in order to be preserved as a fossil, but footprints need to be dry and hard enough to keep their form before they are covered by layers of sand or dirt. Thus, bones and footprints are not generally found together. This was not known when Edward Hitchcock was studying the fossilized footprints he collected from the Connecticut River Valley. He and other scientists were perplexed that they could not find the bones that belonged the animals that had made the tracks, and they kept wondering when they would appear.
Think of it this way: If a dog runs across your muddy driveway, you’ll be able to see the tracks later on and figure that a dog came by. You would see how large or small and how far apart the footprints were, so you could get an idea of the size of the dog, but you wouldn’t be able to tell what breed it was. Similarly, paleontologists can identify in a general way the type of dinosaur that made a set of tracks, but it is not necessarily an exact match. However, we do sometimes hear scientists say that such-and-such a kind of dinosaur made a particular set of prints. They can do this by knowing the foot structure (therapod or sauropod) and size of many different dinosaurs, and thus what general kind of track they would make, and they also know what kinds of dinosaurs lived at the time when the track was made. For example, T rex lived during the late Cretaceous period, about 67-65 million years ago, at the end of the Age of Dinosaurs. Thus, their skeletons and tracks are found only in Cretaceous-age rocks. The sandstones of the Connecticut River Valley were created in the late Triassic – early Jurassic period approximately 200,000,000 years ago, so it’s pretty easy to rule out that the tracks here were made by a T rex.