Are hash referral codes in URL necessary?

803 views Asked by At

Other sites' referral programs generate url's with hash codes to represent the referrer. When the url is sent to and followed by friends and family, some kind of points or recognition system awards the referrer defined by the hash code...but why the hash code? Why not the user id?

1

There are 1 answers

0
Marc B On BEST ANSWER

I can see a few reasons:

  1. Obscure the user ID for privacy reasons
  2. Adds an abstraction layer so you can track where the referal came from. e.g. Hash #1 for links from stackoverflow, Hash #2 for links from expert-sexchange (sic), etc...
  3. Security so that a malicious user couldn't simply try all possible user IDs sequentially and rack up a lot of bogus referals - very trivial if the user IDs are simply numbers.