Do it in person
Though it's tempting to send him a text about your decision to call it quits, a face-to-face breakup (though seemingly old fashioned) is still the respectful way to go. Unless of course he was a cheating jerk, in which case, text away.
Let him down easy
If you know he still likes you and probably won't see the end coming, try your best to be gentle. Do it in a public place (park, cafe) so there's less chance of him making a scene, and don't make him wait for the bad news. Just get it over with in the most calm, direct way possible.
Don't toss blame on him
To avoid a major throw down (or seeing him have a meltdown), try to keep the breakup as succinct as possible. Tell him how you feel and why the relationship isn't working for you any longer, but avoid making it all about him. He'll feel bad enough having been dumped, so try not to make it worse.
More breakup advice