Treat them as though you would like to be treated is the best advice here.
Empathize, don't sympathize.
Be honest yet not derogatory.
Make it quick and simple but not without a clearly defined reason (not my type, don't see you that way, too old/young).
Make sure you don't try to lessen the blow by giving him/her a glimmer of hope that you may be interested in the future if you don't plan on it ever happening.
Avoid doing it in public if possible (no one wants to be rejected in front of a group, but sometimes people ask you out in front of one and it can't be helped)
Although this would be in the aftermath, don't talk about it with your friends (i.e. "you would not believe who just asked me out"). Speaking from a dude's perspective, I ask girls out on a fairly regular basis or at least have to initiate on a regular basis and rejection just happens to us all the time and it's understandable, but getting talked about is never fun.
If you were asked out over text, respond. Being left hanging is also never cool.
If you feel that someone you know is going to ask you out that you don't want to date, try to stop it before it happens. (personal note: I once did this to a girl who literally had my exact schedule in college. All of our classes everyday were identical. It took me about 4 days of hanging out with her to realize that I could not continue this but everyone we saw [friends, even the cashier's at the cafeteria] would talk to us like a couple even though I was just trying to not be rude by ignoring this girl who was going to be with me all day everyday all semester. I didn't realize that she took these comments seriously until she started to really cozy up. It ended badly and publicly.)
Like everything in life, it may seem easier at first to avoid the problem or not tell the whole truth when breaking bad news to someone but also like everything in life it ends a lot better and goes smoother when you tackle it head on and give the situation the respect it deserves.
I would also advise against commentating on the future (lets be friends, I like how things are now so let's not change that). It's not for you to decide at the moment as it's not you that is being hurt but they are. If you don't want to be friends, then the rejection should be enough reason for you to not see them. If you do want to remain friends then the next time you see him/her give them space but don't avoid them either. Just treat them as you normally would but understand if they are not ready to accept that just yet.