I guess there is no correct answer, but this is what can be suggested:
If you see a dog which you think needs help, don't come too close the first time. You need to understand, whether the dog is frightened, scared, aggressive, friendly, etc.
Don't keep back too close. The dog should see you, again, in case it's frightened or aggressive (dog may think you want to attack her and attack first).
If dog is calm, doesn't roar or show its teeth, take its collar with a strong hand. Remember, dogs can feel your fear or weakness. It doesn't mean it will bite you, but the dog can just walk/run away. You can buy some food (sausage, piece of meat) and give it to a dog. While the dog is eating, you can easily read the tag.
Don't come to a dog if it's nervous, aggressive, or shows its teeth. Or if you are frightened or not sure. It's better to ask for help. As I have already said, animals perfectly feel your fear, and it's not good for you.
If the dog appears approachable, remember to use caution and common sense. If you are lucky enough to get close enough to capture him or her, you still stand the risk of being bitten. Even a small dog can inflict a painful wound, and if a dog whose vaccination status is unknown bites you, you will be advised to undergo expensive and painful preventative treatment for rabies.
When approaching the dog, speak calmly and reassuringly to him. Make
sure he can see you at all times as you approach, and perhaps entice
him to come to you by offering a morsel of food.