Generally, a formal tone shows professionalism, while an informal tone engages your audience. Take a formal tone when writing Quick Start Guides and User Manuals, whereas your UX writing can be a little more light-hearted.
In both cases, be factual and candid. Avoid promotional hype, exaggerations, and buzz words. Buzz words such as empower, solution, robust, reach out to give an impression of being pretentious, too lazy to think, or poorly educated. But be positive, too. Focus on what's achieved or improved, rather than what's not.
Avoid emojis, jokes, puns, internet slang, and cultural or religious references.
Address your audience in the second person. When writing in the third person, use inclusive language rather than gender-specific words. For example, don't say:
When operating this machine, user must follow safety instructions in this guide for his own safety. Snapmaker shall not be held responsible if he fails to do so and gets injured.
Instead, say:
When operating this machine, users must follow safety instructions in this guide for their own safety. Snapmaker shall not be held responsible if users fail to do so and get injured.
Or, say:
When operating this machine, persons must follow safety instructions in this guide for their own safety. Snapmaker shall not be held responsible if persons fail to do so and get injured.
With an informal tone, be conversational. Violate grammar once or twice. It's okay to end sentences with prepositions. And it's okay to start a sentence with And or But.