The cell membrane surrounds the cell, letting some things in and keeping others out (the process of diffusion). It also gives the cell some structure, and holds it in place.
The cell membrane is a thing membrane surrounding the cell. It's purpose is much like that of the case for your computer: to keep somethings out, let other things in, and give some structure to the cell. (The other part of the cell responsible for structure is the cell wall.) The membrane is composed mostly of a double layer of phospholipids, arranged tail to tail along the length of the cell. This structure is called the lipid bilayer. The lipid bilayer is formed because of the structure of the lipids. The head of the phospholipids are polar, as is water, and the tails are non-polar. The heads interact with water, but the tails are repulsed by them. Since the cell constantly immersed in water, the lipids form a double layer, with the heads towards the water and the tails inside, away from the water. The surface of the cell membrane is littered with many proteins. There are three main types:
The receptor protien.
The receptor are shaped at both the inside and outside of the cell membrane in such a way that only a certain protein with that inverse (opposite) shape can fit into it. When a protein of the correct shape latches on, the receptor protein triggers a chemical change inside the cell. This allows the body to signal the cells about tasks it needs accomplished: for instance, a certain protein shape could say it needs the cell to step up its production of energy, another could say that the body needs less sugar.
The marker protein.
The function of the marker protein is to tell what type of cell the cell is. This is mostly there so that the immune system can tell friend from foe, and won't attack one of its own cells.
The channel proteins
The channel proteins are one of the most important types of proteins in the cell. They allow larger molecules, such as nitrogen and oxygen, to enter and exit the cell. Since the membrane is very dense, and won't let most molecules through, the channel proteins are the only way that the cell can get the resources it needs to stay alive. It is part of the process of diffusion.
The cell membrane is just inside the cell wall, and surrounds the rest of the cell.