This diagram displays the difference between a positively charged ion (cation), a neutral atom, and a negatively charged atom (anion). Source
Ions are created when an atom loses or gains an electron. Atoms can never lose or gain protons, as this would change the fundamental identity of the atom. The overall charge is determined by the balance between protons and electrons. In the diagram below, the negatively charged atom is said to have a -1 charge while the more positively charged atom has a+1 charge.As was stated before, when an atom loses an electron, it becomes a cation. What kinds of substances can form cations?
Table Salt (NaCl). Image Source
Substances which undergo ionic bonding create a positive cation and a negative anion which are held together by these charge attractions. Salts, such as the NaCl shown above, are a type of solid which is held together by ionic bonding. These ions disassociate in polar solvents, such as water. This is why table salt dissolves in water. In this aqueous state, the Na+ and Cl- ions begin to move around freely in the solution and become ions. These free moving cations and anions are the reason why this new solution is a good conductor of electricity.
Silver (Ag) Bars. Image Source
Metals, which usually form metallic bonds are also prone to ionizing. Silver, shown above, almost always ionizes with a+1 charge. There metallic bonds are slightly weaker than the ionic bonds before and that it why they can sometimes lose electrons without much trouble. The electrons in metals are also delocalized, which means that they can move around freely. This makes it very difficult to accurately predict what charge most metals will form. The metals with form known charges are Ag (+1), Zn (+2) and Sc (+3).
Periodic Table with electronegativies. Darker = Higher Electronegativity. Source
To summarize, when an atom loses an electron it becomes a cation. You will generally elements as cations on the left-hand side of the periodic table, since these elements have a low electronegativity. The same logic can be applied to the other side of the periodic table, where you will generally see elements as anions since they have relatively high electronegativities.