The most useful one would be "Arigatou gozaimasu."
It's pronounced as "a-ri-ga-to-o go-za-i-ma-s".
(It's NOT the most formal indeed; we can be more formal and polite by saying like "Kansya itashimasu" "Koujin no itari de gozaimasu" etc. but I don't think you'd need them any time soon :)
Basically, when you speak to someone
-you just met and don't know well each other
-who is older than you
-who is your teacher or boss,
it's always better to be polite, which means you use "...gozaimasu". (or "Sumimasen" mentioned below.)
When you speak to
-your close friends
-kids
-your own family,
you can go with "Arigatou" (without -gozaimasu).
You can add extra appreciation by putting "Doumo" or "Hontou-ni" before "Arigatou (gozaimasu)"
So it becomes "Hontou-ni arigatou (gozaimasu)" or "Doumo arigatou (gozaimasu)".
When you just want to show light appreciation, "Sumimasen" would work in most situations. It's light appreciation but still polite enough.
"Doumo" is also light appreciation, but it may sound too casual(therefore impolite) depending on the way you say it.