Scenario: As an admin, I need to create accounts for others so that they may access the system. Part of this includes manually inputting a username and password. Note: This part is non-negotiable, as a private system - users cannot create their own usernames or passwords.

The devs have indicated that in order for these fields to meet accessibility requirements, they must have an attribute akin to denoting them as username and password fields.

The reason this is a UX question: Is it OK to drop the accessibility for this so that it doesn't autofill? Neither of these are ideal but which is the less painful experience?

Plan A: Drop A11y - Those who use screen readers will not perceive that the fields are username / password fields because they will be regular input fields. There will be less confusion from all others since the fields are not pre-filled with their own information.


Plan B: Keep A11y - Those who use screen readers WILL perceive that the fields are username/password fields. There will be more confusion from all others since the fields will autofill with their own information.

Open other suggestions as well.

  • Can you just name the input controls something a human would understand as being the username and password, but that the autocomplete algorithm would not? Like "NewUser" and "NewPass" for example.
    – HamHamJ
    Sep 23 '16 at 17:18
  • 3
    Just add autocomplete="off" attributes to the two form fields, no need to change the label Sep 25 '16 at 18:38
  • autocomplete="new-password" is available in some browsers (note the last sentence)…sounds like that should satisfy your requirements, no?
    – Nate Green
    Sep 26 '16 at 20:01

Looking at this scenario the accessibility needs are for the admin. The admin would have needed to sign in themselves before triggering the action to create accounts for others.

For signing in, the admin would need to know which fields are used for his/her username and password. I am assuming you actually want the admin to sign in here.

Once the admin has signed in, when they are creating new accounts, they will now need to know which fields are username and password for the new account they are signing up.

Given your scenario, I don't see why you are considering dropping Accessibility.

I also don't understand why are you concerned about about exposing fields marked as username and password. It suggests someone doesn't understand what accessibility actually means.

If you are just concerned about the auto-fill, then this has absolutely nothing to do with accessibility.

  • 100% - it does correlate. The browser reads Username and Password and then autofills it. If we remove this notation, the fields remain blank, as they should so the admin can create the new account.
    – Pdxd
    Sep 23 '16 at 17:05
  • 2
    If I have understood your comment correctly - the problem of autofill has nothing to do with Accessibility and everything to do with Usability. If an Admin is creating a username and password for other users, then why would you want to have autofill (aka autocomplete) on those username and password fields? It makes no sense to allow the browser to remember what you have typed before in these fields. So you can disable the autofill by adding the autocomplete attribute to the input fields in your html, e.g. autocomplete="off"
    – SteveD
    Sep 26 '16 at 11:23
  • autocomplete="off" is ignored by modern browsers for password fields from what I've read.
    – HamHamJ
    Sep 26 '16 at 17:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.