Background Overall survival for younger patients with type 2 diabetes without kidney disease has improved substantially over time, but whether a similar pattern of improvement is observed in diabetic kidney transplant recipients remained uncertain. We aimed to compare patient outcomes between diabetic and non-diabetic transplant recipients, and to determine the effect of age and era on patient survival. Methods This population cohort study included all primary kidney-only transplant recipients included in the Australia and New Zealand Dialysis and Transplant registry between Jan 1, 1994, and Dec 31, 2012. The primary outcomes were all-cause mortality and death with functioning graft. Associations between outcomes and diabetes status were examined using adjusted Cox regression, and interactions between diabetes status and transplant era and recipient age were examined. Findings Of 10 714 transplant recipients, 985 (9%) had type 2 diabetes. Mortality rates in the first 10 years after transplantation were higher in recipients with diabetes (25·3 per 100 recipients) compared to those without diabetes (11·5 per 100 recipients). Compared with recipients without diabetes, the adjusted hazard ratios (HR) for all-cause mortality and death with a functioning graft in recipients with diabetes were 1·60 (95% CI 1·37–1·86; p<0·0001) and 1·54 (1·28–1·85 p<0·0001), respectively. The association between diabetes status, all-cause mortality, and death with a functioning graft was modified by recipient age (p interaction <0·0001), with the highest risk in recipients with diabetes aged younger than 40 years (adjusted HR 5·16 [95% CI 2·84–9·35], p<0·0001; and 9·83 [4·51–21·43], p<0·0001; for all-cause mortality and death with a functioning graft, respectively). Risk was increased to a lesser extent in recipients with diabetes aged older than 55 years (adjusted HR 1·41 [95% CI 1·17–1·71; p=0·002] and 1·27 [1·02–1·59; p=0·03], for all-cause mortality and death with a functioning graft, respectively). Transplant era did not modify the association between diabetes status and mortality. Interpretation Kidney transplant recipients with type 2 diabetes had substantially poorer patient survival, with 5-year mortality rates exceeding those for non-diabetic recipients by over two times. The magnitude of this survival disadvantage was greatest in recipients with diabetes aged less than 40 years. By contrast with the general population, there was no evidence of improvement in mortality over time among people with type 2 diabetes following kidney transplantation.