  Molecular clouds act as targets for cosmic rays (CR), revealing their
presence through either gamma-ray emission due to proton-proton interactions,
and/or through the ionization level in the cloud, produced by the CR flux. The
ionization rate is a unique tool, to some extent complementary to the gamma-ray
emission, in that it allows to constrain the CR spectrum especially for
energies below the pion production rate ($\approx 280$ MeV). Here we study the
effect of ionization on $H_2$ clouds due to both CR protons and electrons,
using the fully relativistic ionization cross sections, which is important to
correctly account for the contribution due to relativistic CRs. The
contribution to ionization due to secondary electrons is also included
self-consistently. The whole calculation has been implemented into a numerical
code which is publicly accessible through a web-interface. The code also
include the calculation of gamma-ray emission once the CR spectrum
