When writing emails in Japanese, do you use Hiragana or Katakana?

I’m a total beginner in Japanese and got a bit confused.
When writing an email, do people mostly use Hiragana, Katakana, or both?
I’m not sure which one is more appropriate or in what situations each is used.

by MidnightTofu22