Getty/Amazon Prime Video

ANNE HATHAWAY SHUTS DOWN HARRY & OLIVIA THEORY ... Didn't Inspire My Rom-Com!

Anne Hathaway's new rom-com has a lot of the same elements as Olivia Wilde and Harry Styles' one-time real relationship -- but AH says there's no connection there whatsoever.

The actress' latest movie, "The Idea of You," is all about a 40-year-old single mom -- played by Anne -- who gets into a steamy romance with a super young 24-year-old boy band singer, played by Nicholas Galitzine ... which is why folks think OW and HS are the inspiration.

As you know ... Olivia was also a single mom when she hooked up with Harry a couple years back -- and that's why people believe Anne and co. took their story to Amazon Prime.

Unfortunately for everyone who was hoping for this to be true ... Anne shut it down explicitly in a recent interview with Extra this week while promoting the film.

When asked explicitly about the Olivia and Harry theory, AH replied. "No, just no." Instead, Anne says the movie's all about her character pulling out all the stops to bounce back from heartbreak after her ex-husband leaves her in pieces ... so, more generic than anything.

There might be some parallels ... but it's not anything Anne and co. looked to for reference, despite what some might think.

But back to Anne ... she's saying her new role was perfect for her to sink into at this point in her career -- even though some have suggested she's, perhaps, above it. Anne says she just wanted to have some fun, and it looks like she's doing that for this movie.

Click here for info about our online advertising practices.