Loading

Fix Failed Login with No Login History Entry Due to Trailing Space in Username

Дата публикации: Aug 26, 2026
Описание

Newly created users may be unable to log in and see the error "Please check your username and password. If you still can't log in, contact your Salesforce administrator." When checking Login History, no login attempts are registered for the affected user. This typically happens when users are created through the Salesforce API with a trailing space accidentally left in the username field.

Решение

This article explains why a newly created user can fail to log in with no entry appearing in Login History, and how to fix the underlying cause: a trailing space in the username.

Why This Happens

If the user was created through the API rather than the standard Setup UI, the affected user's username may have a trailing space appended to it, which causes every login attempt to fail before it's even recorded.

This issue occurs only when users are created through the API. For example, when uploading a list of users from a CSV file, if a space is accidentally added at the end of a username, that space is not automatically trimmed. Any subsequent login then requires the space to be present exactly as stored, which causes the login to fail silently — without appearing in Login History.

 Steps to Resolve

  1. Navigate to Setup and open the affected user's profile.
  2. Click into the Username field.
  3. Press Ctrl+A (Windows) or Cmd+A (Mac) to highlight all data in the field.
  4. Delete all data in the field.
  5. Carefully re-type the user's username, ensuring there are no typos or trailing spaces at the end.
  6. Save the user record.

Once the username has been corrected, the affected user should be able to log in successfully.

Номер статьи базы знаний

000387757

 
Загрузка
Salesforce Help | Article