<!-- https://learnsql.cpetoday.com/functions/m/date-addweeks -->
# Date.AddWeeks

Language: Power Query M
Category: Date
Syntax: Date.AddWeeks(dateOrDateTime as any, numberOfWeeks as number) as any
Summary: Adds a number of weeks to a date, or subtracts them when the number is negative.
Returns: The new date, or null when the input is null.
Level: Beginner
Related: Date.AddDays, Date.StartOfWeek, Date.AddMonths, Date.WeekOfYear, Date.AddQuarters

## What it does
Date.AddWeeks moves a date by whole weeks. It is the function for a schedule that repeats every week or every two weeks, such as biweekly payroll dates or a weekly lease payment. A week is always seven days, so the result is the same as adding seven times the number of weeks with Date.AddDays.
## Syntax and arguments
- dateOrDateTime: the starting date or datetime.
- numberOfWeeks: the number of weeks to add. A negative number goes back.
## Example
A company pays its staff every two weeks. The payroll team lists the pay dates for the next quarter from the first pay date in the year.

```powerquery
let
    FirstPayDate = #date(2026, 1, 9),
    PayDates = List.Transform({0..5}, each Date.AddWeeks(FirstPayDate, _ * 2)),
    AsTable = Table.FromList(PayDates, Splitter.SplitByNothing(), {"PayDate"}, null, ExtraValues.Error)
in
    AsTable
```

The list starts on January 9, 2026 and moves forward two weeks at a time, so the six pay dates run from January 9 to March 20, 2026. Each date is exactly fourteen days after the one before.
## Example: a second, different use
Find the date of the last Friday of a four week cycle by adding a set number of weeks to the cycle start.
## Things to watch
- A week is seven days. A schedule that is every "half month" needs a different calculation.
- The result keeps the day of the week, so a schedule that started on a Friday stays on Fridays.
- Holidays can move a pay date. Adjust those with a separate list.
- Null in gives null out.
## In business terms
Biweekly payroll, weekly rent and recurring vendor payments are scheduled in weeks. A consistent schedule built from one start date keeps the cash forecast and the payroll calendar aligned.
