Not sure I agree with Kevin on this, I have checked out some sites and they seem to suggest it does not do much good and in some cases aggravates it, I have not found a website that says peeing on a jellyfish sting is a good idea. I have copied and pasted a part from one of the websites :
Jellyfish stings are caused by contact with the creature’s tentacle, which triggers millions of stinging cells called nematocytes to pierce the skin and inject venom.
The best way to deactivate the nematocytes is to get out of the water, remove the tentacles with something other than your bare fingers, and splash vinegar or some other acidic compound on the wound. Once the stinging cells are disabled, you should scrape them off with a credit card or some other flat object.
But the pH of urine is closer to that of water than vinegar, and it can cause the nematocytes to swell and release more venom, worsening the sting. Only after the nematocytes have been deactivated and removed might urine soothe the wound, because of the liquid’s warmth alone — but warm water will serve just as well.