How To Display Username In URL For Drupal Site

| Drupal Development | 20 seen

I know for some experienced Drupal developers such question might sound bizarre, because  - hey..it's a piece of cake..

I have been subscribed to the LinkedIn Drupal group and exactly such question arise here:

hey guys is there any way to display username in URL when user logged in like example www.example.com/username

was asked by one of the group members

I added my solution for this question on that post already and I decided to share it on my blog as well since other Drupal users might ask such question as well.

Solution: How to display username in URL

At first you will need to have pathauto module to be enabled on your Drupal site and all the other required modules - (Path, Token). Once you have installed a pathauto module go to the File Path section (admin/config/search/path/patterns) scroll down until User Paths and in blank field enter: [user:name] 

Drupal User Paths

Drupal User Paths

Dont forget to save your configuration and then bulk update your existing path.

Hope this explains how to add username in Drupal URL.

If you have any Drupal related question, feel free to contact me and I will try to find a solution for your question in a blog post.

 

Latest articles

Berlin Brandenburg Airport

In April 2026, I had my first experience with Berlin Brandenburg Airport (BER) while flying the Riga–Berlin–Riga route with airBaltic. This was my first time using Berlin’s main international airport, and overall, it left a solid impression—modern, functional, and relatively easy to navigate. About a decade ago, I had the chance to travel through…

Germany |
Embedded thumbnail for Mumbai & Goa / India Trip

Mumbai & Goa / India Trip

It has already become something of a tradition for us - escaping the cold during our daughter’s winter school break and trading grey skies for warmth, color, and a slower rhythm of life. Each year, we carve out about three weeks to leave Tbilisi behind and head somewhere sunnier. And more often than not, that “somewhere” turns out to be India.Our…

India |