Varsågod is usually translated as 'you're welcome' but can also mean something like 'please' and/or 'here you go'.
There are three main contexts in which you might hear or use this word.
Firstly, if someone says tack (thank you) to you, perhaps for holding a door open for you or after you do them a favour, you can respond varsågod (you're welcome). Alternative options in this context might be ingen orsak (no trouble) or det var så lite (it was nothing), but varsågod is the most common.
And it can also be used in a nicely passive aggressive way if you don't receive a tack when you might expect it, so for example if you hold the door open and someone passes through it without a nod or word of thanks, you could mutter varsågod under your breath.
The second context for using varsågod is when giving something to someone, such as when a waiter hands you your drink or cake, or when your boss hands out agendas at the start of a meeting. Here, it means something like 'here you go', similar to prego in Italian.
And finally, it can be used as a slightly formal way of saying 'please'. Swedish doesn't really have a direct translation for please: when ordering food, for example, the customer tends to simply say tack (thank you). But if you want to stress politeness and formality, you can start a sentence with something like varsågod och, which literally means something like 'please be so kind as to…' For example: Varsågod och sätt dig (please sit down).
You may have already guessed that it can be broken down into three parts: var så god, which literally mean 'be so good/kind'. French-speakers might notice a similarity to the French term for 'please', s'il vous plait (literally: if it pleases you).
Varsågod can also be used in the plural, varsågoda, when addressing groups of more than one person. If you're in a restaurant, a waiter might show you to your table with the word varsågod (if you're on your own) or varsågoda (for groups), meaning something like 'please sit down'.
And if you use instant messaging or text with Swedes, you can abbreviate the word to vsg, and they'll know what you mean.