I am locked in a staring contest with the spinning rainbow pinwheel—why won’t it even force quit?—and the hum of panic is seeping through my limbs. Suddenly the screen of my laptop goes white. Please don’t tell me it just crashed. I have so much work left to do! Later, the Genius at the Apple Store not only confirms my fears but also adds that my data is unrecoverable. As I have been writing about Buddhism, Stoicism, and cultivating non-attachment, the cruel irony of such timing is not lost on me. Perhaps the universe is trying to tell me something.

I leave the Genius Bar, wondering what on earth I’m going to do, and as I step out into the summer sun, I am suddenly flooded with gratitude for the perfect weather. The trip to the Apple Store has taken me near the High Line in New York, and while I’m soaking up the greenness of this city oasis, it occurs to me that the situation could have been so much worse. Remember how guilty you felt about not getting more work done yesterday? Maybe it’s a hidden blessing. You would have lost whatever you had written. The thankful thoughts continue all afternoon, and while I am fully present to the implications of being a writer without a computer, I’m unusually happy.

The Roman Stoic philosopher Epictetus suggests that “we are disturbed not by events, but by the views which we take of them.” Is it really objectively “bad” that my hard drive crashed? Stoicism would argue: no, events are not inherently good or bad. Only our thoughts about them make them so. So maybe I had unconsciously let go of attachment to my computer? I guess my research rubbed off on me.

Understanding the Philosophy of Stoicism

How do you lead a good life? Stoicism arose in 301 BC as one of many philosophies of ancient Greece and Rome that sought to answer this question. The Stoics proposed that the ultimate goal of life is to live in accordance with nature. This can be understood as “the responsibility of excelling by bringing our own nature to perfection,” as psychotherapist and Stoic scholar Donald Robertson explains in his book Stoicism and the Art of Happiness. Above all, the Stoics valued the uniquely human trait of reason and believed that living rationally was the ultimate way to honor nature’s laws. Doing so also comes with the added promise of reaching eudaimonia, a smoothly flowing life of enlightened happiness and emotional resilience—a Hellenistic nirvana.

Related: The 5 Aspects of Life That Contribute to True Happiness

Marcus Aurelius, one of the last Roman Stoics, wrote, “Nature has not willed that my unhappiness should depend on another.” In other words, it is unnatural to draw happiness from our surroundings, though most people do. Stoicism recognizes that by removing the labels of “good” and “bad” interactions, “desirable” and “undesirable” events, we can release ourselves from the emotional burden of attachment. In its place, we can cultivate an unshakeable happiness within ourselves, independent of any external influence. Stoics consider common values such as health, wealth, and reputation to be preferred states of being, but of ultimate insignificance to our happiness.

So how exactly do we train ourselves to let go of these attachments?

The ancient Stoics prescribed a series of intellectual exercises to discipline desire and attachment. A few examples you can try include cultivating self-awareness in the “here and now;” in the morning, mentally rehearsing the day ahead and preparing to meet all outcomes with indifference and equanimity; in the evening, reviewing and reflecting upon your actions of the day; projecting affectionate feelings toward all human beings; and periodically imagining potential catastrophes that could befall you—including your own death—and how to deal with them according to Stoic principles.

If you find that some of these exercises sound strikingly similar to mindfulness practice, you are not alone. Robertson said, “I think there are actually more similarities between Stoic prosoche (“attention” in Greek) and the modern literature on mindfulness [as opposed to older schools of Buddhism]. Stoicism is appealing to a surprisingly diverse group of people: academics, therapists, military personnel, businessmen, people coping with illness…[those] interested in Buddhism and yoga. They might say, ‘It’s like a Western form of Buddhism, Hinduism, or yoga,’ or ‘It’s like a form of mysticism but more rational and philosophical.’”

Patrick Ussher, a scholar at the University of Exeter agrees. He compares Stoicism to the secularized mindfulness practice developed by teachers like Stephen Batchelor and Jack Kornfield that has gained such a strong following in the West. Western Buddhism, as he calls it, still remains true to foundational Buddhist texts but has shifted its focus away from reincarnation and mysticism, preferring to emphasize practices for daily life. Thich Nhat Hanh advocates a similar approach called “engaged Buddhism,” the path of the bodhisattva who actively addresses injustice in the world.

Related: Ritual Inspiration: Sharon Salzberg

Ussher writes that beyond the shared focus on awareness and mental space, Western Buddhism and Roman Stoicism share a common belief that humans are inherently disposed toward goodness and wisdom. The two also share an ultimate goal of living ethically in the present in order to positively influence the future, taking responsibility for our own happiness, and disciplining our “passions” (the Stoic term for material desires).

Greg Lopez, the founder of the New York City Stoics Meetup, adds that the two philosophies also share the practice of repeating axioms that remind us to be present. “The universe is change, life is opinion.” “Be free from passion, but full of love.” While they may sound like something your yoga teacher would say, these quotes come directly from Marcus Aurelius’ daily practice. Buddhist mindfulness mantras such as “Let go” convey similar a similar reminder to find joyful imperturbability in the present.

Lopez, however, is quick to point out that despite these similarities, the two philosophies differ in significant ways. He and Ussher both note that Western Buddhism tends to focus on awareness of the present mind to turn down the volume on discursive thinking. Stoicism, however, focuses on cultivating an awareness of the present in order to channel the mind into reflecting actively on events in the past or future.

Stoicism as a Modern Practice

Buddhism and secular mindfulness have secured a strong foothold in the West over the past half-century, but the ancient Stoics are becoming increasingly popular among those seeking to perfect the art of living. Well-known practitioners range from life hacker Tim Ferriss to former president Bill Clinton, and Stoic writings have greatly influenced psychotherapeutic techniques like Cognitive Behavioral Therapy.

Related: The Emergence of Mindfulness in Business

Scientific research on mindfulness meditation indicates that the practice can have profound effects on conditions ranging from depression to chronic pain. In 2012, Ussher designed an informal pilot study at the University of Exeter called Stoic Week to determine if Stoicism offers similarly quantifiable benefits. After just one week of living a Stoic lifestyle, participants reported a 10% increase in psychological well-being and a 10% decrease in negative emotions. Stoic Week is now an annual online event attracting more than 3,200 participants. While further research is required, the positive effects of Stoicism are clearly apparent.

Stoic principles helped me positively manage the loss of my hard drive, and as I type these final words from a public library computer, I continue to feel grateful. Not having a laptop this week has paradoxically made me happier in many ways, encouraging me to sign up for a library card and to finally start playing the guitar that’s been gathering dust in the corner of my bedroom. I’ll be glad to have my laptop back, but more aware that my happiness is not dependent on the health of my hard drive.

Want to learn more? Both Lopez and Robertson will be speaking about the similarities between mindfulness and Stoicism at this year’s annual STOICON, on Saturday, October 15 in New York City. For more information about STOICON, Stoic Week, and applying Stoic principles to your everyday life, visit the University of Exeter’s blog, Stoicism Today.