There's not much we know about the early Universe, we don't even know that much about our own Solar System and how it came about. The solar system went from a ball of dust to something somewhat resembling what we see today relatively quickly, in just 10 million years.
This was happening some 4.6 billion years ago, a very violent time. It was during that time that many planetesimals were created, which later went on to form protoplanets and then planets as we know them today.
shows that Vesta, one of the largest and heaviest asteroids in our Solar System, may have been a planetesimal and had molten core.
The core has long since cooled, but it stayed hot long enough for heavy elements like iron to drop to the center and create a magnetic field, due to their motion.
This magnetic field lasted for several millions of years, perhaps for the first 100 million years of its existence. It was enough to magnetize all the materials on the planet and the magnetization persists today.
This is how several researchers were able to determine that Vesta had a dynamo, aka a molten core. Surprisingly enough, they didn't even have to leave the lab, let alone planet Earth, to do it, instead they analyzed a meteorite originating from Vesta, which landed in Antarctica 31 years ago.
The scientists were able to determine the magnetization of the rock's crystals and discovered that their magnetic field was aligned, something that happens when the rock cools under the influence of a strong magnetizing source, like Vesta's early magnetic field.
The trick was eliminating other sources of magnetization and getting down to the oldest and longer lasting. Rocks can be magnetized by any source, but the strength of the magnetic field and how long the influence lasts determines how strong the magnetization effect is.
By successively demagnetizing the rock fragment they were analyzing, scientists were able to remove weaker magnetization effects. They then determined the age of the meteorite which they found to be around 3.7 billion years. This would mean it would have had to be magnetized that long ago.
3.7 billion years ago is still long after Vesta had cooled and lost its internal magnetic field; however, the rocks on its surface remained magnetized and influenced this piece that eventually landed on Earth.
The results suggest that Vesta is the smallest known planetary object to have had molten core, though the solar system was filled with this type of objects in the early days.