The pyramids of Ancient Egypt were built to house the tombs of pharaohs so that they could continue their existence in the afterlife according to Egyptian beliefs. The pyramids served as elaborate tombs where pharaohs were buried along with treasures for the next world.