The charge of an electron is considered to be negative by convention and this charge is equal and opposite to the charge of a proton, which is considered to be positive by convention. The net charge of an ion is not zero because its total number of electrons is unequal to its total number of protons.
A cation is a positively charged ion with fewer electrons than protons  while an anion is a negatively charged ion with more electrons than protons.  Opposite electric charges are pulled towards one another by electrostatic force, so cations and anions attract each other and readily form ionic compounds.
Ions consisting of only a single atom are termed atomic or monatomic ions, while two or more atoms form molecular ions or polyatomic ions. In the case of physical ionization in a fluid (gas or liquid), "ion pairs" are created by spontaneous molecule collisions, where each generated pair consists of a free electron and a positive ion.  Ions are also created by chemical interactions, such as the dissolution of a salt in liquids, or by other means, such as passing a direct current through a conducting solution, dissolving an anode via ionization.
The word ion was coined from Greek neuter present participle of ienai ( Greek: ἰέναι), meaning "to go". A cation is something that moves down ( Greek: κάτω pronounced kato, meaning "down") and an anion is something that moves up ( Greek: ano ἄνω, meaning "up"). They are so called because ions move toward the electrode of opposite charge. This term was introduced (after a suggestion by the English polymath William Whewell)  by English physicist and chemist Michael Faraday in 1834 for the then-unknown species that goes from one electrode to the other through an aqueous medium.   Faraday did not know the nature of these species, but he knew that since metals dissolved into and entered a solution at one electrode and new metal came forth from a solution at the other electrode; that some kind of substance has moved through the solution in a current. This conveys matter from one place to the other. In correspondence with Faraday, Whewell also coined the words anode and cathode, as well as anion and cation as ions that are attracted to the respective electrodes. 
Svante Arrhenius put forth, in his 1884 dissertation, the explanation of the fact that solid crystalline salts dissociate into paired charged particles when dissolved, for which he would win the 1903 Nobel Prize in Chemistry.  Arrhenius' explanation was that in forming a solution, the salt dissociates into Faraday's ions, he proposed that ions formed even in the absence of an electric current.   
Ions in their gas-like state are highly reactive and will rapidly interact with ions of opposite charge to give neutral molecules or ionic salts. Ions are also produced in the liquid or solid state when salts interact with solvents (for example, water) to produce solvated ions, which are more stable, for reasons involving a combination of energy and entropy changes as the ions move away from each other to interact with the liquid. These stabilized species are more commonly found in the environment at low temperatures. A common example is the ions present in seawater, which are derived from dissolved salts.
As charged objects, ions are attracted to opposite electric charges (positive to negative, and vice versa) and repelled by like charges. When they move, their trajectories can be deflected by a magnetic field.
Electrons, due to their smaller mass and thus larger space-filling properties as matter waves, determine the size of atoms and molecules that possess any electrons at all. Thus, anions (negatively charged ions) are larger than the parent molecule or atom, as the excess electron(s) repel each other and add to the physical size of the ion, because its size is determined by its electron cloud. Cations are smaller than the corresponding parent atom or molecule due to the smaller size of the electron cloud. One particular cation (that of hydrogen) contains no electrons, and thus consists of a single proton - much smaller than the parent hydrogen atom.
Anion (−) and cation (+) indicate the net electric charge on an ion. An ion that has more electrons than protons, giving it a net negative charge, is named an anion, and a minus indication "Anion (−)" indicates the negative charge. With a cation it is just the opposite: it has less electrons than protons, giving it a net positive charge, hence the indication "Cation (+)".
Since the electric charge on a proton is equal in magnitude to the charge on an electron, the net electric charge on an ion is equal to the number of protons in the ion minus the number of electrons.
An anion (−) ( // ANN-eye-ən, from the Greek word ἄνω (ánō), meaning "up" ) is an ion with more electrons than protons, giving it a net negative charge (since electrons are negatively charged and protons are positively charged). 
There are additional names used for ions with multiple charges. For example, an ion with a −2 charge is known as a dianion and an ion with a +2 charge is known as a dication. A zwitterion is a neutral molecule with positive and negative charges at different locations within that molecule. 
Cations and anions are measured by their ionic radius and they differ in relative size: "Cations are small, most of them less than 10−10 m (10−8 cm) in radius. But most anions are large, as is the most common Earth anion, oxygen. From this fact it is apparent that most of the space of a crystal is occupied by the anion and that the cations fit into the spaces between them." 
Ions are ubiquitous in nature and are responsible for diverse phenomena from the luminescence of the Sun to the existence of the Earth's ionosphere. Atoms in their ionic state may have a different color from neutral atoms, and thus light absorption by metal ions gives the color of gemstones. In both inorganic and organic chemistry (including biochemistry), the interaction of water and ions is extremely important[ citation needed]; an example is energy that drives the breakdown of adenosine triphosphate ( ATP)[ clarification needed].
Ions can be non-chemically prepared using various ion sources, usually involving high voltage or temperature. These are used in a multitude of devices such as mass spectrometers, optical emission spectrometers, particle accelerators, ion implanters, and ion engines.
As signalling and metabolism in organisms are controlled by a precise ionic gradient across membranes, the disruption of this gradient contributes to cell death. This is a common mechanism exploited by natural and artificial biocides, including the ion channels gramicidin and amphotericin (a fungicide).
The ionizing effect of radiation on a gas is extensively used for the detection of radiation such as alpha, beta, gamma, and X-rays. The original ionization event in these instruments results in the formation of an "ion pair"; a positive ion and a free electron, by ion impact by the radiation on the gas molecules. The ionization chamber is the simplest of these detectors, and collects all the charges created by direct ionization within the gas through the application of an electric field. 
The Geiger–Müller tube and the proportional counter both use a phenomenon known as a Townsend avalanche to multiply the effect of the original ionizing event by means of a cascade effect whereby the free electrons are given sufficient energy by the electric field to release further electrons by ion impact.
When writing the chemical formula for an ion, its net charge is written in superscript immediately after the chemical structure for the molecule/atom. The net charge is written with the magnitude before the sign; that is, a doubly charged cation is indicated as 2+ instead of +2. However, the magnitude of the charge is omitted for singly charged molecules/atoms; for example, the sodium cation is indicated as Na+ and not Na1+.
An alternative (and acceptable) way of showing a molecule/atom with multiple charges is by drawing out the signs multiple times, this is often seen with transition metals. Chemists sometimes circle the sign; this is merely ornamental and does not alter the chemical meaning. All three representations of Fe2+, Fe++, and Fe⊕⊕ shown in the figure, are thus equivalent.
Monatomic ions are sometimes also denoted with Roman numerals, particularly in spectroscopy; for example, the Fe2+ example seen above is referred to as Fe(II) or FeII. The Roman numeral designates the formal oxidation state of an element, whereas the superscripted Indo-Arabic numerals denote the net charge. The two notations are, therefore, exchangeable for monatomic ions, but the Roman numerals cannot be applied to polyatomic ions. However, it is possible to mix the notations for the individual metal centre with a polyatomic complex, as shown by the uranyl ion example.
If an ion contains unpaired electrons, it is called a radical ion. Just like uncharged radicals, radical ions are very reactive. Polyatomic ions containing oxygen, such as carbonate and sulfate, are called oxyanions. Molecular ions that contain at least one carbon to hydrogen bond are called organic ions. If the charge in an organic ion is formally centred on a carbon, it is termed a carbocation (if positively charged) or carbanion (if negatively charged).
Monatomic ions are formed by the gain or loss of electrons to the valence shell (the outer-most electron shell) in an atom. The inner shells of an atom are filled with electrons that are tightly bound to the positively charged atomic nucleus, and so do not participate in this kind of chemical interaction. The process of gaining or losing electrons from a neutral atom or molecule is called ionization.
Atoms can be ionized by bombardment with radiation, but the more usual process of ionization encountered in chemistry is the transfer of electrons between atoms or molecules. This transfer is usually driven by the attaining of stable ("closed shell") electronic configurations. Atoms will gain or lose electrons depending on which action takes the least energy.
For example, a sodium atom, Na, has a single electron in its valence shell, surrounding 2 stable, filled inner shells of 2 and 8 electrons. Since these filled shells are very stable, a sodium atom tends to lose its extra electron and attain this stable configuration, becoming a sodium cation in the process
On the other hand, a chlorine atom, Cl, has 7 electrons in its valence shell, which is one short of the stable, filled shell with 8 electrons. Thus, a chlorine atom tends to gain an extra electron and attain a stable 8- electron configuration, becoming a chloride anion in the process:
This driving force is what causes sodium and chlorine to undergo a chemical reaction, wherein the "extra" electron is transferred from sodium to chlorine, forming sodium cations and chloride anions. Being oppositely charged, these cations and anions form ionic bonds and combine to form sodium chloride, NaCl, more commonly known as table salt.
Polyatomic and molecular ions are often formed by the gaining or losing of elemental ions such as a proton, H+, in neutral molecules. For example, when ammonia, NH3, accepts a proton, H+—a process called protonation—it forms the ammonium ion, NH+4. Ammonia and ammonium have the same number of electrons in essentially the same electronic configuration, but ammonium has an extra proton that gives it a net positive charge.
Ammonia can also lose an electron to gain a positive charge, forming the ion NH+3. However, this ion is unstable, because it has an incomplete valence shell around the nitrogen atom, making it a very reactive radical ion.
Due to the instability of radical ions, polyatomic and molecular ions are usually formed by gaining or losing elemental ions such as H+, rather than gaining or losing electrons. This allows the molecule to preserve its stable electronic configuration while acquiring an electrical charge.
The energy required to detach an electron in its lowest energy state from an atom or molecule of a gas with less net electric charge is called the ionization potential, or ionization energy. The nth ionization energy of an atom is the energy required to detach its nth electron after the first n − 1 electrons have already been detached.
Each successive ionization energy is markedly greater than the last. Particularly great increases occur after any given block of atomic orbitals is exhausted of electrons. For this reason, ions tend to form in ways that leave them with full orbital blocks. For example, sodium has one valence electron in its outermost shell, so in ionized form it is commonly found with one lost electron, as Na+. On the other side of the periodic table, chlorine has seven valence electrons, so in ionized form it is commonly found with one gained electron, as Cl−. Caesium has the lowest measured ionization energy of all the elements and helium has the greatest.  In general, the ionization energy of metals is much lower than the ionization energy of nonmetals, which is why, in general, metals will lose electrons to form positively charged ions and nonmetals will gain electrons to form negatively charged ions.
Ionic bonding is a kind of chemical bonding that arises from the mutual attraction of oppositely charged ions. Ions of like charge repel each other, and ions of opposite charge attract each other. Therefore, ions do not usually exist on their own, but will bind with ions of opposite charge to form a crystal lattice. The resulting compound is called an ionic compound, and is said to be held together by ionic bonding. In ionic compounds there arise characteristic distances between ion neighbours from which the spatial extension and the ionic radius of individual ions may be derived.
The most common type of ionic bonding is seen in compounds of metals and nonmetals (except noble gases, which rarely form chemical compounds). Metals are characterized by having a small number of electrons in excess of a stable, closed-shell electronic configuration. As such, they have the tendency to lose these extra electrons in order to attain a stable configuration. This property is known as electropositivity. Non-metals, on the other hand, are characterized by having an electron configuration just a few electrons short of a stable configuration. As such, they have the tendency to gain more electrons in order to achieve a stable configuration. This tendency is known as electronegativity. When a highly electropositive metal is combined with a highly electronegative nonmetal, the extra electrons from the metal atoms are transferred to the electron-deficient nonmetal atoms. This reaction produces metal cations and nonmetal anions, which are attracted to each other to form a salt.