Meiosis is the type of cellular division within multicellular sexual organisms that forms sex cells (as opposed to mitosis, which is the form of cellular division that creates more somatic, or body, cells). Sperm and egg are sex cells. Sex cells contain half the number of chromosomes as somatic cells (the haploid number). This assures that the original number of chromosomes (the diploid number) that is characteristic for a species is reestablished upon fertilization of the egg by the sperm. For example, humans have 46 chromosomes. Human sperm and egg have 23 chromosomes. Thus, upon fertilization:
sperm (containing 23 chromosomes) + egg (containing 23 chromosomes) = 46 chromosomes
In order to reduce the diploid number of chromosomes to the haploid number within sex cells, the chromosomes of cells undergoing meiosis undergo one duplication (aka- replication) and two divisions. Directly prior to meiosis (during the S phase of interphase), DNA replicates within the parent cell (the original cell that will undergo division). By the end of Meiosis I, there are two cells that each have the same number of chromatids as the parent cell. Meiosis II results in a splitting of each of the two cells formed at the end of Meiosis I. During Meiosis II, the second division of genetic material occurs. Thus, at the end of Meiosis II, there are 4 cells sex cell that each contain half the number of chromosomes as the original parent cell.
Please refer to the link below. This link will take you to a picture that explains each step of Meiosis in much more detail.