In the early 20th century, Einstein and many other scientists believed the universe was static and eternal. To reconcile this with his equations, which suggested that gravity would cause a static universe to collapse, Einstein introduced the cosmological constant. This term provided a repulsive force that could balance the gravitational attraction, allowing for a stable, static universe.