President Donald Trump is seeking to dismiss the defamation lawsuit brought against him by a journalist who accuses him of rape, arguing in a filing on Friday that New York courts have no jurisdiction over him.

Elle magazine “Ask E. Jean” advice columnist E. Jean Carroll, who wrote a book that accused Trump of raping her in a Manhattan department store, had sued the president in New York Supreme Court in November for denying her claims and saying he’d never even met her.

Lawyers for Trump in their motion to dismiss argue that the “alleged defamatory statements were made by President Trump not while he was in New York, but rather while he was in Washington D.C,” and therefore, he can’t be sued in the Empire State.

“Her lone assertion that President Trump is a ‘resident’ of New York—besides being erroneous (he has resided in Washington D.C. for the past three years)—is insufficient to confer personal jurisdiction over him for the alleged statements,” the filing states.

The attorneys also want to put a pause on sharing any discovery material in the case, until a hearing decides whether the court has jurisdiction over Trump.

The discovery “will necessarily involve intrusive and burdensome document and testimonial discovery from party and non-party witnesses regarding purported events dating back to the mid-1990’s,” and “should be stayed,” the motion states.

Carroll’s lawsuit stems from statements Trump made shortly after a preview of her book “What Do We Need Men For? A Modest Proposal,” was published in New York Magazine in June.

In it, Carroll, 76, claimed Trump raped her in a Bergdorf Goodman changing room around 1995.

Shortly after the article’s publication, Trump said: “I’ve never met this person in my life.”

“She is trying to sell a new book—that should indicate her motivation. It should be sold in the fiction section,” he said.

Later in June, Trump said in an interview that “I’ll say it with great respect: Number one, she’s not my type. Number two, it never happened. It never happened, OK?”

Trump also claimed that New York Magazine was trying to boost readership with the story and said, “If anyone has information that the Democratic Party is working with Ms. Carroll or New York Magazine, please notify us as soon as possible,” Carroll’s lawsuit charges.

“Trump falsely implied and affirmatively intended to imply that Carroll had been paid money to invent the rape accusation against him,” the lawsuit states.

Carroll’s counsel, Roberta Kaplan, called the idea that Trump can no longer be sued in New York “obviously ridiculous,” in a statement to The Post.

“When E. Jean’s case was filed, Donald Trump maintained a home in New York, was registered to vote in New York, paid taxes in New York, and had been sued in New York on numerous occasions—including since 2016—without any objection,” the statement said.

“Tellingly, as his papers make clear, what this motion is really about is a transparent effort to avoid discovery at all costs in a case involving a sexual assault—despite the fact that the Judge has already ordered that discovery should go forward irrespective of the filing of any motion to dismiss.”