They were intended by the Ancient Egyptians to serve as burial places for Old Kingdom pharaohs.
However, the Mayan pyramids (located in Mexico) were built for offering sites for their human sacrifices, where they were either burned or their heads were cut off and their vital organs were eaten by the priests.
Ancient Egyptians believed in an afterlife in which they could continue to enjoy their most valuable possessions. As such, it was important to prepare very special tombs (and thus comfortable afterlives) for the pharaohs and their queens. The pyramids were build expressly as tombs for these rulers.
Thier main purpose was to function as tombs.
tombs
The Ancient Egyptians constructed pyramids as tombs for their pharaohs (kings).
There are 138 pyramids discovered in Egypt as of 2008.
To protect their bodies.
They were built as tombs.
The Pyramids of Giza
Leaving all conspiracy theories behind, the main purpose of pyramids were to serve as final resting place (tombs) for pharaohs.
The Ancient Egyptians constructed pyramids as tombs for their pharaohs (kings).
I believe that they are three main pyramids in Giza.
Pharaoh tombs.
There are 138 pyramids discovered in Egypt as of 2008.
For the Pharaoh tombs
To protect their bodies.
You can't tell without seeing the pyramids.
The pyramids that you are talking about were built to hold the remains of dead Egyptian (and other) pharoahs.
Egyptian pyramids were basically large elaborate tombs/memorials. Pharaohs commissioned the pyramids to be built so they could be buried inside.
They were burial places for important emperors.
They were built as tombs.