ODK Collect date field appears limited to year 1900 on Android device

Hi,
I am testing an XLSForm in ODK Collect for a correction workflow.
I have a date question for date of birth. In the form, the constraint only checks that the person is at least 18 years old:
int((today()-.) div 365.25) >= 18
There is no minimum year constraint in the XLSForm.
However, on Android, when opening the date picker, it seems I cannot select years earlier than 1900. For our use case, we may need to register dates of birth for people born before 1900.
I would like to ask:

  1. Is there any known Android or ODK Collect limitation in the date picker that prevents selecting years earlier than 1900?
  2. Is this device-specific, Android-version-specific, or an ODK Collect limitation?
  3. Is there a recommended workaround for cases where dates before 1900 are needed?
  4. Would using separate fields for year / month / day be the best approach in this case?
    What I have tried:
  • Verified that the XLSForm itself has no minimum year restriction
  • Confirmed the only constraint is age >= 18
  • Tested the form on Android through ODK Collect
  • The issue seems to be in the date picker UI rather than the XLSForm logic
    I can share the XLSForm and screenshots if needed.
    Thanks.

1. What is the issue? Please be detailed.

2. What steps can we take to reproduce this issue?

3. What have you tried to fix the issue?

4. Upload any forms or screenshots you can share publicly below.

Hi @vertexi

When you get a chance, please introduce yourself here. I'd also encourage you to add a real picture as your avatar because it helps build community!

By default, the Android date picker allows selecting dates between 1900 and 2100. We’ve never added any option to override this, and it has always worked this way.

It works the same way regardless of the Android device you use or the version of ODK Collect.

I would use a simple text question with a regex to validate the date format. For example:
^\d{4}-(0[1-9]|1[0-2])-(0[1-9]|[12][0-9]|3[01])$

1 Like