Plasma core fuelling is a key issue for the development of steady-state scenarios in large magnetically-confined fusion devices, in particular for helical-type machines. At present, cryogenic pellet injection is the most promising technique for efficient fuelling. Here, pellet ablation and fuelling efficiency experiments, using a compact pellet injector, are carried out in Electron Cyclotron Resonance and Neutral Beam Injection heated plasmas of the stellarator TJ-II. Ablation profiles are reconstructed from light emissions collected by silicon photodiodes and a fast-frame camera system, under the assumptions that such emissions are loosely related to the ablation rate and that pellet radial acceleration is negligible. In addition, pellet particle deposition and fuelling efficiency are determined using density profiles provided by a Thomson Scattering system. Furthermore, experimental results are compared with ablation and deposition profiles provided by the HPI2 pellet code, which is adapted here for the stellarators Wendelstein 7-X (W7-X) and TJ-II. Finally, the HPI2 code is used to simulate ablation and deposition profiles for pellets of different sizes and velocities injected into relevant W7-X plasma scenarios, while estimating the plasmoid drift and the fuelling efficiency of injections made from two W7-X ports.