Skip to content

Support for last / past multiple months or weeks #1270

@AndreaSottana

Description

@AndreaSottana

Are there any plans to add support for expressions such as "in the last 2 months" or "in the past week", or "in the past 3 months" etc?
At the moment they are not recognised.
As these expressions tend to mean a span of time rather than a single point in time, it would be appropriate to return the starting point of that span of time (considering the end point is today)

For example, if today is 14 May 2025, I would expect something like this

import dateparser
print(dateparser.parse("last 2 months"))

>>> 2025-03-14 11:53:12.301002

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions