One night in 2015, travelling around Australia on a book tour, I lay on my bed in the room of a posh hotel admiring the job I’d done on the door. Wide packaging tape sealed the crack where the door met the jamb, and a damp towel was wedged against the bottom.

If a person from housekeeping had knocked and then heard the sound of ripping tape before the door opened, they might have felt the need to call security. But there was method in my madness. Part of the hotel’s poshness was the lavish use of fragrance. Scented candles made the foyer smell like a flower shop. An air freshener filled the lift with patchouli. Reed diffusers wafted musk along the corridors. Luckily, the rooms themselves were free of fragrance. Once I was sealed in like a pharaoh, I could breathe freely.

Perfume and I go back a long way. My mum’s bottle of Arpège by Lanvin sat on its own doily on her dressing table and before she and Dad went out she’d put some on. She showed me the right way to do it. You puffed a few squirts into the air and walked through the mist as it slowly drifted down. See, darling? Like that. You don’t want to overdo it.

I felt very womanly to have my own bottle of scent when I got older and started going out with boys. I’d leave the house feeling sumptuous and desirable. One night at a party, a woman I admired exclaimed: “Oh, you’re wearing White Linen!” and I basked in her tone of congratulation.

‘It was a huge relief to understand this was no random thing’: Australian author Kate Grenville, who has written The Case Against Fragrance. Photograph: Darren James

But half an hour after I’d left the house I’d have a piercing headache, my nose would be stuffed up, my eyes would be sore, and I’d be cranky. If I thought about it at all, it was to blame myself – I must be tense and anxious.

Shopping was another problem. I was irritable and headachy after just a few minutes of flipping through the clothes racks, and just wanted to get out. When I started work, I gravitated to jobs that didn’t involve people groomed and scented for success. I found work in the shabby back rooms of places that made documentary films. By the time I was 30 I called myself a writer, spending days alone in my work room where the only scent was from a sprig of jasmine in a jar.

But leaving the house often meant getting a headache. I was frequently unwell in ways that no doctors could help. The worst thing about it was the unpredictability. Why this day and not that day? Why here but not there? There was a feeling of frustration and helplessness in having my life dominated by random lightning-strikes of headache and brain fog. Life took on a treacherous feel, of never knowing where or when the next bolt would hit.

A few years later the penny dropped. A friend brought a bottle of perfume as a gift. As soon as I dabbed it on – even while I was still saying “Thank you so much” – I felt the headache starting. I went into the bathroom and scrubbed the perfume off my skin. The headache faded. I remember thinking, why has it taken me so long to work this out? It’s simple. It’s not life that gives me a headache, it’s perfume.

It was a huge relief to understand this was no random thing: it was as plain and orderly as cause-and-effect. When I was exposed to fragrance, I got a headache. When I wasn’t, I didn’t. Now I could do something about it. Over the following weeks, I replaced all the products in the house with fragrance-free ones. In the supermarket I’d surreptitiously open packages to test them, because the most surprising things – toilet paper, bin liners, cat litter – turned out to smell of pine forests or roses.

With every source of fragrance I eliminated, my life improved. Leaving the house was still a kind of Russian roulette, but the helplessness and frustration of not understanding was replaced by a degree of acceptance.

But I wasn’t ready to go public. I’d never heard of anyone who got sick from perfume, symbol of everything desirable and glamorous. In fact, it felt a little shameful, as if I was indulging a neurosis. Talking about it, even to friends, seemed awkward. The secrecy and isolation became something of a burden in themselves.

I had a few strategies for dealing with it. When friends swooped in for a peck on the cheek, I’d make a fending-off gesture, and when they said: “Oh, got a cold?” I’d nod. I’d suggest our meetings took place in cafés with an outdoor terrace and I’d sit upwind.

Shame evolved into something more like anger one night when I went with friends to the opera. By bad luck the woman behind me was drenched in especially pungent perfume. Within minutes my head was pounding, my eyeballs felt too big for their sockets and my brain was a blur. The sublime music seemed like little more than noise.

I was so obviously ill that night that I had to share my secret with my friends. As I’d feared, they could hardly believe what I was telling them. “Perfume?” they said. “You get sick from perfume?” But once over their surprise, they were sympathetic. One of them asked: “Are there a lot of others like you?” and I realised it was time to find out more.

Three days later I was on the book tour, sealed into that hotel room. I opened the laptop, searched for “fragrance headache” and within minutes I was deep in the science of scent. I read on with growing exhilaration. It turned out I wasn’t a lone eccentric after all, but in company with millions of others.

Now I’ve outed myself by writing a book about fragrance, I’m unembarrassed about telling people I can’t hug them and probably won’t come to their party, because the fragrance will make me sick. The amazing thing is how many of them understand. Oh yes! They say. Me too!

I still wish I could wake up one day free of the fragrance-headache tyrant, but I’ve stopped waiting for that to happen. My life has shaped itself around this fact, and it’s made me who I am. Who knows if I’d have become a writer if other options had beckoned? Writing has let me travel the world and plunge into the peculiarities of human behaviour. If an odd and awkward problem with fragrance is the price for that, it might just have been worth it.

The Case Against Fragrance by Kate Grenville, is out now. Order it for £11.04 from bookshop.theguardian.com