A detailed investigation of the structure and magnetic properties of Tm2Fe17−xGax (x = 0, 1, 2, 3, 4, 5, 6, 7, and 8) compounds has been performed by means of x-ray-diffraction, neutron-diffraction, magnetization, and ac-susceptibility measurements. Crystal-structure studies have shown that the prepared samples are single phase with the hexagonal Th2Ni17 for x ⩽ 3 and the rhombohedral Th2Zn17 structure for x ≥ 5. In Tm2Fe13Ga4 the Th2Zn17 structure coexists with the Th2Ni17 structure. Substitution of Ga for Fe in Tm2Fe17 leads to an increase of the unit-cell volume, which is linear with the Ga concentration. In Tm2Fe17−xGax, the saturation magnetization at 1.5 K decreases linearly with increasing Ga content with a rate of 2.3 μB per substituted Ga atom. The Curie temperature is found first to increase with increasing Ga content, going through a maximum value of 485 K at about x = 3, then to decrease. Between x = 6 and 7, a minimum value of TC is reached and for higher x values TC increases again. X-ray-diffraction measurements on magnetically aligned Tm2Fe17−xGax powders show that the compounds with x ⩽ 6 have an easy-plane type of magnetic anisotropy, whereas the compounds with x ≥ 7 exhibit easy c-axis anisotropy at room temperature. All Tm2Fe17−xGax compounds exhibit a spin-reorientation transition at low temperature, except for the sample with x = 6, which shows an easy-magnetization direction perpendicular to the c axis in the temperature range from 5 to 300 K. For x ⩽ 5, the spin-reorientation temperature is found first to increase with x and then to decrease, having a maximum value of 211 K at about x = 3. In the samples with x ≥ 7, an easy-plane anisotropy was observed at low temperature, but an easy-axis preference of the magnetization at room temperature was observed. The results obtained for Tm2Fe17−xGax indicate that the mutually competing Tm- and Fe-sublattice anisotropies both change their sign with increasing Ga concentration. © 1998 American Institute of Physics.