How to set recovery question in Okta Sign in widget


How can I use the okta sign in widget to let the user set their challenge question and answer in the reset password flow?


  1. The user gets a ‘reset password’ email with link.
  2. The link goes to our app integrated with Okta sign in widget.${recoveryToken}
  3. The user has to answer the recovery challenge. So the widget navigates to /signin/recovery-question

In the UI, there is an input box for answer only. How can I set it up so user can also set their recovery question if this is the first time?

What I see is this:

What I need to see is this:
if user has not set the recovery question, ask user to create it, then update password: