From the user view point and for small and average organic molecules:
EI (electron ionization, also electron impact):
energetic electrons interact with gas phase atoms or molecules to produce ions. As a consequence, if you have some rather functionalized molecule which is non-aromatic, in general you can forget to see molecular peak. The impact is so powerful that molecule splits into multiple fragments.
ESI (Electrospray ionization):
It is especially useful if you want to avoid fragmentation of your molecule and you wish to observe molecular peak. Principally developed for proteins but widely used now-a-days. The technique of the choice if you wish to couple your MS with GC or HPLC (easy to filter off carrier gases and solvents).
I think that, Electron Impact( hard ionizaton) shows molecular ion peak with large fragments of signals and in case of Electron Spray Ionization ( kind of soft ionization) and it shows m/z is very accurate with the help of nanospray ( capillary size 1u)
EI and ESI are processes of creating ions, the entities that can be seen by mass spectrometers. These processes take place at the ion source, one of the essential parts of any mass spec setup. In the first the molecules in gas phase are bombarded with high energy electrons (usually 70 eV) in order to get these ions. In the second the ions "jump" from a solution (sprayed in a strong electric field) into the gas phase. This later process is soft and the ions you get are usually the intact analyte plus one or more ions, such as H+, that were also in the sprayed solution.
Electron Impact Ionization (EI) is the ionization technique,by default, that is used in GCMS. ESI, on the other hand, is a very popular ionization technique in LCMS.