Title: Validate Username
Last modified: June 3, 2020

---

# Validate Username

 *  [gpsathas](https://wordpress.org/support/users/gpsathas/)
 * (@gpsathas)
 * [6 years ago](https://wordpress.org/support/topic/validate-username/)
 * I want to prohibit the usage of the dot (.) special character from usernames.
   I have searched about sanitization but I couldn’t realize where should I put 
   the code to disallow the dot (.) character. Can somebody help me with that?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Matt Robinson](https://wordpress.org/support/users/mattyrob/)
 * (@mattyrob)
 * [6 years ago](https://wordpress.org/support/topic/validate-username/#post-12930625)
 * [@gpsathas](https://wordpress.org/support/users/gpsathas/)
 * I think you may be able to do this using the `validate_username` filter.
 * You could either return an invalid response if the username contains ‘.’ or strip
   them out and continue.
 * [https://developer.wordpress.org/reference/functions/validate_username/](https://developer.wordpress.org/reference/functions/validate_username/)
 *  Thread Starter [gpsathas](https://wordpress.org/support/users/gpsathas/)
 * (@gpsathas)
 * [6 years ago](https://wordpress.org/support/topic/validate-username/#post-12930639)
 * I am not very sure how can I do that. I not such an “expert”. Can you please 
   elaborate on that?

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Validate Username’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 2 replies
 * 2 participants
 * Last reply from: [gpsathas](https://wordpress.org/support/users/gpsathas/)
 * Last activity: [6 years ago](https://wordpress.org/support/topic/validate-username/#post-12930639)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
