I have created a view for user profile page. I also want to show the user's current email address and last login time. It is working fine for admin but email and last login time is not visible to authenticated user on front end. I have granted the View User Information permission to authenticated users but no success after that too. Is it a permission issue or something else ? What I am missing ?

  • I have the same behavior, very strange, maybe a bug? Feb 14, 2018 at 16:01

2 Answers 2



I set up a test View myself and confirmed the issue you reported. Upon some search, I see this is intended behaviour.

There is a thread discussing it here: https://www.drupal.org/project/drupal/issues/2799049

The thread has a very simply Core patch to resolve the issue that could be applied. Or, there's also information on using hook_entity_field_access() to grant field-level access to User fields.


************************ORIGINAL INFO***************************

From what you've said, it seems like it should work as you'd expect.

One thing you can try is checking the "Disable SQL rewriting" checkbox in your View. This will bypass ALL permission checking for the View. It is located in the Query Options setting in the Advanced section of your View config.

If checking this works then you'll know that,at least, the issue is permissions related.

  • Your solution don't solve the problem. Feb 14, 2018 at 16:00
  • See new comment edit above. Feb 14, 2018 at 16:22
  • I don't think that the patch will solve the problem, I made the view and I can't see my own information, and to see my own information I don't need this permission because I can see my email from my user page. Feb 14, 2018 at 17:03
  • The core patch is just to make it simpler to then alter the default access rules and make that information visible. You still need some custom code in hook_entity_field_access() or use a contrib module that allows that. I believe there is one mentioned in the issue. Have a look at what the test module in that issue is doing.
    – Berdir
    Feb 15, 2018 at 7:20

You have to give "Administer users" permission to view the email and last login details of any user.

Note: This permission needs to be given for trusted user.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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