As with all behavior, if the behavior of pulling on the leash is reinforced it will get stronger. Reinforcement is anything the dog wants, likes or enjoys, so if he gets to sniff the grass, chase leaves, or visit a friendly stranger, and he got to those reinforcements by pulling on the leash then the behavior of "pulling" just got reinforced.
To change the "pulling" behavior you just need to stop reinforcing it and reinforce some other "better" behaviour instead. So don't let your dog access anything he likes, wants or enjoys by "pulling", and when he is walking nicely nicely beside you without any tension on the leash make sure you reinforce that behavior with the things he likes, wants or enjoys.
A couple of training options for changing the behavior is to stop as soon as your dog puts any tension on the leash and not move forward again until your dog releases that tension, when he does make sure you reinforce it. Another option is to change direction; if your dog pulls one way then change direction and go the other, when your dog catches up to you reinforce him for being beside you, right where you want him to be.
Using a short leash will allow you to react quicker when your dog pulls, and using a clicker to "mark" the good behavior of not pulling will help teach your dog the new rules. Besides the reinforcements your dog may find along the walk, taking some tasty treats along and giving them when the leash is loose will help reinforce the new behaviour of loose leash walking.