The aims of this study were (1) to evaluate the ability of computed tomography (CT) to predict the chemical composition of live pigs and carcasses, (2) to compare the chemical composition of four different sex types at a commercial slaughter weight and (3) to model and evaluate the chemical component growth of these sex types. A total of 92 pigs (24 entire males (EM), 24 surgically castrated males (CM), 20 immunocastrated males (IM) and 24 females (FE)) was used. A total of 48 pigs (12 per sex type) were scanned repeatedly in vivo using CT at 30, 70, 100 and 120 kg and slaughtered at the end of the experiment. The remaining 44 were CT scanned in vivo and slaughtered immediately: 12 pigs (4 EM, 4 CM and 4 FE) at 30 kg and 16 pigs each at 70 kg and 100 kg (4 per sex type). The left carcasses were CT scanned, and the right carcasses were minced and analysed for protein, fat, moisture, ash, Ca and P content. Prediction equations for the chemical composition were developed using Partial Least Square regression. Allometric growth equations for the chemical components were modelled. By using live animal and carcass CT images, accurate prediction equations were obtained for the fat (with a root mean square error of prediction (RMSEPCV) of 1.31 and 1.34, respectively, and R2=0.91 for both cases) and moisture relative content (g/100 g) (RMSEPCV=1.19 and 1.38 and R2=0.94 and 0.93, respectively) and were less accurate for the protein (RMSEPCV=0.65 and 0.67 and R2=0.54 and 0.63, respectively) and mineral content (RMSEPCV from 0.28 to 1.83 and R2 from 0.09 to 0.62). Better equations were developed for the absolute amounts of protein, fat, moisture and ash (kg) (RMSEPCV from 0.26 to 1.14 and R2 from 0.91 to 0.99) as well as Ca and P (g) (RMSEPCV=144 and 71, and R2=0.76 to 0.66, respectively). At 120 kg, CM had a higher fat and lower moisture content than EM. For protein, CM and IM had lower values than FE and EM. The ash content was higher in EM and IM than in FE and CM, while IM had a higher Ca and P content than the others. The castrated animals showed a higher allometric coefficient for fat and a lower one for moisture, with IM having intermediate values. However, for the Ca and P models, IM presented higher coefficients than EM and FE, and CM were intermediate.