The overall findings remained directionally consistent across subgroup and landmark analyses.<h4>Conclusions</h4>The CRP-TyG composite index was independently associated with a higher risk of incident malignancy in hospitalized patients with diabetes and showed a clear nonlinear dose-response pattern. The gene discussed is CRP; the disease is diabetes mellitus.