If you have a student loan or any other loan open and you decide to pay the loan off early then it certainly won't harm your credit score any.
Paying off your student loan early could increase your credit score by a little bit and it shows you're good with credit.
But having the student loan open for the entire loan term is much better for your credit rating overall because it builds up a payment history that gets reported and listed on your credit score and over the time period it builds your credit much more.
Other loan companies like to see a good payment history on your credit report so it's better to keep the student loan or other loans open for the full term to continue to build your credit rating.
But paying off your student loan earlier than the loan term will not hurt your credit.