Mara Wilson says she's still appalled by the public's scrutiny of Britney Spears.

The former child star, known for her roles in "Matilda" and "Mrs. Doubtfire" in the 1990s, published an opinion piece on Tuesday in which she slams the Hollywood industry for setting women, especially young female stars, up for failure.

In her op-ed written for The New York Times, Wilson, now 33, speaks to what she calls "The Narrative" that's been perpetuated by media and the public for years. She describes it as "the idea that anyone who grew up in the public eye will meet some tragic end."

Wilson shared one of her earliest memories of being publicly shunned after a journalist referred to her as a "spoiled brat" in an article when she was just 13. She noted she was "ruined" at the time despite having been "trained to seem, to be, as normal as possible — whatever it took to avoid my inevitable downfall."

ROBIN WILLIAMS REMEMBERED BY ‘MRS. DOUBTFIRE’ CO-STARS 25 YEARS LATER: ‘HE WAS OPEN AND HONEST ABOUT HIS ADDICTION’

In the same article, Wilson says she was quoted saying she "hated" Spears.

Mara Wilson shares her thoughts on thte mistreatment of Britney Spears from the media and the public.

Mara Wilson shares her thoughts on thte mistreatment of Britney Spears from the media and the public. (Gilbert Carrasquillo/FilmMagic)

"I didn’t actually hate Britney Spears. But I would never have admitted to liking her. There was a strong streak of 'Not Like the Other Girls' in me at the time, which feels shameful now — although hadn’t I had to believe that, when I’d spent so much of my childhood auditioning against so many other girls?" Wilson analyzes. "Some of it was pure jealousy, that she was beautiful and cool in a way I’d never be. I think mostly, I had already absorbed the version of The Narrative surrounding her."

Wilson goes on to share the ways in which she related to Spears in the '90s. Her reflection comes just a couple weeks after the "Framing Britney Spears" documentary sparked renewed interest in the singer's  conservatorship battle against her father, Jamie Spears, and the intense scrutiny she faced as a worldwide pop star.

PIERCE BROSNAN REUNITES WITH ‘MRS. DOUBTFIRE’ CO-STARS 25 YEARS LATER

"The way people talked about Britney Spears was terrifying to me then, and it still is now," Wilson writes. "Her story is a striking example of a phenomenon I’ve witnessed for years: Our culture builds these girls up just to destroy them. Fortunately people are becoming aware of what we did to Ms. Spears and starting to apologize to her. But we’re still living with the scars."

Like Spears, Wilson says she experienced her fair share of being sexualized at a young age. 

"I never appeared in anything more revealing than a knee-length sundress. This was all intentional: My parents thought I would be safer that way. But it didn’t work. People had been asking me, 'Do you have a boyfriend?' in interviews since I was 6," Wilson writes.

BELLA THORNE CONDEMNS 'DISGUSTING' TREATMENT OF BRITNEY SPEARS, SAYS 'WE'RE ALL PART' OF THE PROBLEM

The "Framing Britney Spears" documentary which has brought renewed attention to the downfalls of the singer's superstardom and conservatorship battle against her father, Jamie Spears (left).

The "Framing Britney Spears" documentary which has brought renewed attention to the downfalls of the singer's superstardom and conservatorship battle against her father, Jamie Spears (left). (Chris Farina/Corbis via Getty Images)

Fortunately for Wilson, she says she had one thing Spears apparently didn't in her early career: support from her family.

"Many moments of Ms. Spears’s life were familiar to me. We both had dolls made of us, had close friends and boyfriends sharing our secrets and had grown men commenting on our bodies. But my life was easier not only because I was never tabloid-level famous, but because unlike Ms. Spears, I always had my family’s support. I knew that I had money put away for me, and it was mine. If I needed to escape the public eye, I vanished — safe at home or school," Wilson continues.

Wilson says watching the public's scrutiny of Spears reminded her of what she didn't want for herself in the limelight.

HOWARD STERN SUPPORTS BRITNEY SPEARS, #FREEBRITNEY MOVEMENT AFTER YEARS OF MOCKING POP STAR

"I followed the uproar over her Rolling Stone magazine cover story, where the first line described her 'honeyed thigh,' and the furor on AOL message boards when her nipples showed through her shirt. I saw many teenage actresses and singers embracing sexuality as a rite of passage, appearing on the covers of lad mags or in provocative music videos. That was never going to be me, I decided," Wilson says.

CLICK HERE TO SIGN UP FOR OUR ENTERTAINMENT NEWSLETTER

Wilson also reflected on the now-viral photos from 2007 when Spears was caught on camera smashing a photographer's car with an umbrella. She writes that the singer's so-called "breakdown" "never needed to happen."

"The Narrative was forced upon her," Wilson writes, "but the reality was she was a new mother dealing with major life changes. People need space, time and care to deal with those things. She had none of that."

CLICK HERE TO GET THE FOX NEWS APP

Wilson added that she was "never sexually harassed on a film set." She claimed her harassment came in other ways, though, such as "at the hands of the media and the public."

She concluded that she's taken back the reins of telling her own story. Her "Narrative," she says, is one "I can write myself."