Early beliefs (based on religion) often said the Earth was at the center of the universe. While early astronomers could observe the sky, there were many things they didn't understand. Why did Mars, for example, sometimes reverse course in the sky and then resume marching in the same direction as other planets? Some astronomers came up with elaborate geometrical constructions called epicycles, which were supposed to predict the planets' seemingly chaotic movements.
A simpler solution was proposed by Nicholas Copernicus in the 1500s, who published material showing the sun at the center of the universe, with the Earth revolving around it just like other planets. (This also was proposed by Aristarchus of Samos in Greece in the third century, but his writings were not well-known to the Western world at the time). This solved the problem of the epicycle, and it was backed up with other evidence. For example, Galileo's discovery of moons orbiting Jupiter in 1610 showed that not everything revolved around the Earth. Religious authorities were not pleased, but with time the evidence outweighed the arguments.
Hubble at 25: Brief History of the Hubble Space Telescope
As telescopic technology advanced, we eventually learned the sun is not the center of the universe, either. In the 1750s, it was believed that the Milky Way was a large collection of stars with its own center. By the early 1900s, observations of novas (starbursts) in other galaxies showed that they were further away than the Milky Way. Eventually, astronomer Edwin Hubble found evidence that the universe was expanding equally in all directions, with no true center.