Your first step is to add a Date field to your form. Once inside the Form Builder, select the Date / Time form field from your available Fields. Next, open Field Options and click the Advanced Options to select the Date Picker for the Date Type.
Once you’ve added your Date field, you’ll need to copy the following code snippet to your site.
And that’s it! You’ve now limited the years available inside your date picker. Would you like also allow for a date range in your date picker? Check out our tutorial on How to Allow Date Range or Multiple Dates in Date Picker.
Action Reference: wpforms_wp_footer_end
Q: Can I also apply this to the Date Dropdown?
A: Absolutely, but the Date Dropdown can only be used with manual date ranges. Following this tutorial, just follow this tutorial to change the year range
$args['years'] = range( 2019, 2020 ); to enter the range of years you want to limit.