Masses of stuff on the web about this. As you haven't given us much (none) info on what phone you have and as every phone is slightly different it would be hard for us to advise. Quite apart from that it is very very easy to brick a phone when rooting it. I have rooted a few and had about a 50/50 success rate. I wouldn't root anyone elses phone I only do my own. Some phones cannot be rooted and there are different levels of rooting. Phone manufacturers do not like nor want you to root your phone as it takes their spyware off and all their adverts and other crap. Having said that though that is the main reason for rooting any smartphone. You may have to install a custom rom and XDA delelopers have these.
As I have said I wouldn't advise anyone to root their phones. It can result in a completely useless device. Any research you do and any experimenting you carry out you do so at your own risk. Nobody on this forum or anywhere else has any responsibilty for what you do to your smart phone.