Tidal energy has attracted great attention due to its massive potential and eco-friendly nature. Performance of ducted turbines used in tidal energy conversion is significantly influenced by tip clearance and associated leakage flow. In this work, a method of variable-depth (VD) groove is developed to suppress the tip leakage vortex (TLV) and the tip leakage vortex cavitation (TLVC) around a NACA0009 hydrofoil, and different variable-depth laws are proposed to improve the suppressing effect. The flow pattern around the hydrofoil is investigated on basis of numerical method, which is validated by experiment results. Results show that this groove method not only effectively suppresses primary TLV by high-velocity flow impingement, but also reduces the primary TLVC by increasing local pressure in vortex core regions. In addition to the intrinsic primary TLV and secondary TLV, some local small-scale vortices are witnessed in vicinity of the groove. Among the VD grooves, the divergent groove shows an optimal effect on suppressing vortex and cavitation in general. Increasing the divergent groove depth at hydrofoil pressure side causes the shrinkage of the primary TLV but a larger scale of the additional vortices in vicinity of the groove. The suppressing effect of the divergent groove on the TLVC reaches a peak when the pressure side depth is increased to 50% of the tip clearance size. The lift coefficient of the hydrofoil is sensitive to the groove pressure side depth, by decreasing which can effectively improve the lift-drag performance of the hydrofoil.