My insomnia is cured. I take my medication, turn off the lights, and fall straight to sleep. Waking up rested, having energy all day, productivity, and better moods – I am not ungrateful for these benefits.

But a little part of me misses those wakeful late nights.

My relationship with sleep has always been a bit strained. As a small child I sleepwalked (sometimes leaving the house), often had nightmares (thanks, “Fantasy Island), and developed a habit of counting to 20 over and over until I fell asleep. I thought if I could survive whatever horror was beyond my cracked door for a count of 20, I would be safe.

The battle with insomnia began in college, bound tightly to anxiety. My mind could not tolerate quiet or stillness and rebelled against sleep until I crashed from exhaustion. I could tolerate dysfunctional sleep habits because I was young and passionate. I could motor through days after no sleep, fueled by the excitement of fresh adulthood. 

Around this time, over-the-counter pain killer brands started to market their “PM” versions – analgesic plus antihistamine to help with sleep. They helped me sleep sometimes, but my drive to fret the night away proved more powerful.

In my 30s, being an insomniac wasn’t fun anymore. I was tired, depressed, not functioning at the top of my game. I dreaded mornings, pepped myself with junk food, and stole naps when I could. When I asked a doctor for help, I was given the now ubiquitous and oft-abused Ambien.

Ambien and I were like co-dependent but mildly hostile sisters for years. She worked for me at first, but I was afraid to use her too often. I hoarded her for those nights that my anxiety ballooned and I desperately needed sleep. I was taking her once a month, then once a week, then every other night, then every night.

Then she wasn’t helping me sleep so much as turning me into a late-night internet-surfing zombie, eating random pantry contents that I couldn’t even taste. Again, I asked the doctor for help. This combination of pills and tricks has finally cured my insomnia:

• Trazadone – an antidepressant that turns my nighttime anxiety off like a switch.

• Melatonin – the hormone that regulates sleep cycles and makes me go thunk within 30 minutes of taking it.

• Syncing with the sun – I set an alarm at sunrise and another at sunset. I feel best when I wake up at sunrise, and shut down at sunset (this is the toughest part).

• Going dark – Ideally, when that sunset alarm goes off, I would shut down the television, laptop and phone. I can read, do yoga, talk to my husband, or do other low-tech activities until bedtime. This gets harder as sunset creeps earlier, but the earlier I “shut down,” the earlier I fall asleep.

Now that I have several months of healthy sleep under my pillow, I rarely nap, I get more exercise, and I’m more productive than I have been in years. But I’m not always eager to crash at a reasonable hour.

I told my husband recently, “I wish I could stay up late watching TV, but my stupid medicine works too well.”

As the memory of insomnia fades, it gets projected through a soft-focus romantic filter. I remember my solitary hours (so rare with small children at home), my creative bursts, hours of “Real Housewives” on the sofa. Maybe my craving for late night activity is conflated with memories of my reckless youth.

I think it’s time for me to accept my improved grown-up sleep habits and let insomnia fade into the background with other nostalgic memories like, Hey remember when we could drink till the sun came up without even getting a hangover?