You can use useParams in a nested route by calling it in the nested component to access the parameters relevant to that route.