In dense clouds of the interstellar medium, dust grains are covered by ice mantles, dom- inated by H2O. CO and CO2 are common ice components observed in infrared spectra, while infrared inactive N2 is expected to be present in the ice. Molecules in the ice can be dissociated, react or desorb by exposure to secondary ultraviolet photons. Thus, different physical scenarios lead to different ice mantle compositions. This work aims to understand the behaviour of 13CO : N2 and 13CO2 : N2 ice mixtures submitted to ultraviolet radiation in the laboratory. Photochemical processes and photodesorption were studied for various ratios of the ice components. Experiments were carried out under ultra-high vacuum conditions at 12K. Ices were irradiated with a continuous emission ultraviolet lamp simulating the secondary ultraviolet in dense interstellar clouds. During the irradiation periods, fourier-transform infrared spectroscopy was used for monitoring changes in the ice, and quadrupole mass spectrometry for gas- phase molecules. In irradiated 13CO2 : N2 ice mixtures, 13CO, 13CO2, 13CO3, O2, and O3 photoproducts were detected in the infrared spectra. N2 molecules also take part in the photochemistry, and N-bearing molecules were also detected: NO, NO2, N2O, and N2O4. Photodesorption rates and their dependence on the presence of N2 were also studied. As it was previously reported, 13CO and 13CO2 molecules can transfer photon energy to N2 molecules. As a result, 13CO and 13CO2 photodesorption rates decrease as the fraction of N2 increases, while N2 photodesorption is enhanced with respect to the low UV-absorbing pure N2 ice.