We present deep observations of the field of the magnetar CXOJ164710.2-455216 in the star cluster Westerlund 1, obtained in the near-infrared with the adaptive optics camera NACO@VLT. We detected a possible candidate counterpart at the {em Chandra} position of the magnetar, of magnitudes $mathrm{J} = 23.5 pm 0.2$, $mathrm{H} = 21.0 pm 0.1$, and $mathrm{K}_mathrm{S} = 20.4 pm 0.1$. The K$_{rm S}$-band measurements available for two epochs (2006 and 2013) do not show significant signs of variability but only a marginal indication that the flux varied (at the 2 $sigma$ level), consistent with the fact that the observations were taken when CXOJ164710.2-455216 was in quiescence. At the same time, we also present colour--magnitude and colour--colour diagrams in the J, H, and K$_{rm S}$ bands from the 2006 epoch only, the only one with observations in all three bands, showing that the candidate counterpart lies in the main bulk of objects describing a relatively well--defined sequence. Therefore, based on its colours and lack of variability, we cannot yet associate the candidate counterpart to CXOJ164710.2-455216. Future near-infrared observations of the field, following-up a source outburst, would be crucial to confirm the association from the detection of near-infrared variability and colour evolution.