What it means to set a good example
I've discussed this theme in short points elsewhere, but it's worth dedicating a proper article to the whole notion of "setting a good example", and what that means. Side note: I initially got the idea to write about this from Michael on X/Twitter, inspired by one of his posts.
Nietzsche had an interesting thought experiment known as "eternal recurrence", where you live your life over and over for eternity. It's a challenge for one to live life in a way that they would be willing to repeat eternally. Can you confidently say you would repeat your current life eternally, as it is now?
The general notion of the phrase "setting a good example" assumes you're living according to values and standards you genuinely believe in. You're setting a good example for yourself, and embody the values you advocate for, where, as a side-effect, other people can identify those traits, and hopefully feel inspired by your example. Ultimately though, this shouldn't be done for other people, whether it's for their approval or inspiration to better themselves, it's something you should do for your own self first. Everything else that results from that is a positive side-effect.
It's important to identify your values and principles, to embody them, and seek to live them every day. I don't mean to lean into pop-psychology with that phrasing, but it's really the best way to live. I know speaking from personal experience, when I've had periods of time where I've adhered to a consistent set of values and principles, I always found myself happier, more productive, and generally feeling great. But every single time I've strayed from that path (and I've had those moments, I'm not suggesting I'm some shining example of living a principled life), I've found myself feeling lost, miserable, and just very moody.
I know it can be difficult to figure out what your values and principles are, and to then live by them. Mainstream culture today doesn't advocate for that lifestyle, so finding examples of other people, sources of inspiration, can be difficult (although there's definitely a large, growing movement that does embody these positive attributes). But the important thing is, once you've identified those core principles, then you should make every effort to live by them in your daily life. This means making decisions that align with your values, even when faced with challenging obstacles.
The other aspect to all of this is self-reflection. Regularly reflecting on your actions and decisions helps ensure that you are staying true to the example you want to set for yourself. Speaking from personal experience, any time I've found myself falling out of line with the life I want to live, it's always because I didn't self-reflect on my actions, even the smallest actions (everything compounds). It's like a feedback loop you need to consistently be in. This is why if you ever find yourself acting out of alignment with your values, the reflection process helps you identify it and make changes accordingly.
If you have a commitment to personal growth and self-improvement, this means you recognise areas where you can grow, and target a plan to work on them. The initial stages are going to be difficult, but once it's become an integrated part of your life, it's easy. Take going to the gym as an example: initially, it was difficult for me to do, there was always this sense of resistance, but having been consistent at it for long enough, I now look forward to it, and will cancel other activities to ensure I get my 5 days/week in (following Michael's program has definitely helped). And because of this commitment, I've become a positive influence on others, most notably my own mother. She's been going to the gym 4 days/week for a year and a half now, because my actions inspired her to join a gym (usually we go once a week together).
After a while of living by your own values and principles, setting this personal standard, you come to reinforce your self-respect and integrity. This is probably the most important point out of everything else discussed. Why? Because even if others are not watching, you know that what you're doing is right, and knowing that for your own self matters because it leads to a sense of personal pride. So many things are done today for others' approval/validation, but when you do something without that consideration, you know it's genuine.
This is why it's also important to never doubt yourself, that what you're striving to live by is somehow 'wrong' because it's at odds with mainstream culture. Again, speaking from personal experience, this is easily a slippery slope, and can see you lose sight of who you are, and what you want in life. If you find yourself surrounded by friends who live the total opposite of how you want to, then it's time to find better friends (I've always found these people end up resenting you, being jealous, when you're obviously improving your life).
Having a strong sense of what you stand for can guide you during difficult times. It's easy to feel lost and directionless when faced with adversity, and you're not always guaranteed to come out unscathed. But when you find yourself faced with a difficult decision, an ethical dilemma, whatever it is, having clear principles provides a roadmap to navigate those challenges. It's worked for me in the past when I had them, but when I didn't, the challenge of it all was even more difficult.
Lastly, you want to strive for consistency in your actions and decisions. This will help reinforce your values, and makes it more likely that you will adhere to them in challenging situations. I know it's difficult to maintain this sense of consistency, especially when it might feel as if you're not getting anything in return, and sure, it will feel that way initially, but I can guarantee that after a while, you'll feel that sense of personal pride at having stayed true to yourself.