Resetting the Form Data

Learn how to reset the form data with Formik.

Often, we want to reset a form by returning its values to those set in initialValues. This could be after we have successfully submitted the form or when the user clicks a “Reset” or “Clear” button.

With Formik, we can reset our form values to those values stated in initialValues. We can also change the values in the next initialValues object that our form will use.

Get hands-on with 1200+ tech skills courses.