Invalid verification code. Please login or reset your password I am sending the set Password URL to a user to set their password after ADMIN create a user in CP.

I am using craft()-&gt;users-&gt;getPasswordResetUrl($user) to generate the URL for set password which is look like https://&lt;my domain&gt;/actions/users/setpassword?code=8MHKqfmt6Te%5C_dyuCouL4PMaT%7EE%7EV9jNO&amp;id=8bf376ca-e260-44b9-9ad2-0cc623fe4c4c However, I got intermittent user report they get "Oops! Invalid verification code. Please login or reset your password." message pop up after click the link.

In general.php, I have 'verificationCodeDuration' =&gt; 'P7D' to make sure the code could last for 7 days.

Does anyone has idea how to verify the code in DB? Looks the verficationCode column in DB is encrypted. Does anyone know how to solve that issue? Thanks
If it's just some users, I've seen some email clients split the link with a newline and when users click it, they don't get the full token in the URL producing an invalid one when Craft tries to verify it.

In those cases, it's recommended that the user manually copy and paste the full URL instead of clicking on it.