Redirect 'user' and 'user/uid' to 'users/name' I have been trying to redirect the default user url of '/user' to the url alias of '/users/username'.

If i go to '/user/uid' it redirects properly but if i type in '/user' the url doesn't redirect.

Using hook_preprocess_user_profile() I can print arg(0) and arg(1) with drupal_set_message() and it display that arg(1) exists as the uid on '/user'. 

I have tried

function mymodule_preprocess_user_profile(&amp;$vars) {
  global $user;
  //print_r($vars);
  if (arg(0) == 'user' &amp;&amp; arg(1) == $user-&gt;uid){
    //drupal_set_message('0'.arg(0).'1'.arg(1));
    drupal_goto("users/$user-&gt;name");
  }
}


but this end up in an endless redirect. Is it possible to even accomplish this?
By redirecting /user you'll be redirecting the login page to a user page.  When someone goes to /user and logs in they are automatically redirected to /user/username.  Unless you have login disabled(not advised) I can't see what you want to achieve, can you explain further?

Redirects are best handled by the path redirect module

or using rules in .htacces or etc/apache2/httpd.conf