To calculate the number of weeks between two dates in Excel, subtract the start date from the end date and divide the result by 7. For example, if your start date is in cell A2 and your end date is in cell B2, the formula is =(B2-A2)/7. This works because Excel stores dates as sequential serial numbers, meaning a difference of 1 equals one day.

What You'll Need

  • Microsoft Excel (any version)
  • A worksheet containing two cells with valid date entries
  • Basic knowledge of how to enter a formula into a cell

Step-by-Step

  1. Enter Your Dates: Input your start date in one cell (e.g., A2) and your end date in another cell (e.g., B2). Ensure these are formatted as "Date" cells so Excel recognizes them correctly.
  2. Select the Result Cell: Click on the empty cell where you want the number of weeks to appear (e.g., C2).
  3. Enter the Basic Formula: Type =(B2-A2)/7 and press Enter.
    • Note: Always put the later date first to avoid getting a negative number.
  4. Adjust the Formatting: If the result looks like a date (e.g., "January 7, 1900") instead of a number, you must change the cell format. Go to the Home tab, locate the Number group in the ribbon, and change the dropdown menu from "Date" to "General" or "Number."
  5. Choose Your Rounding Method (Optional): Depending on your needs, you may want the result to be a whole number rather than a decimal.
    • For exact decimals: Leave the formula as =(B2-A2)/7.
    • To round down to the nearest full week: Use =INT((B2-A2)/7). This ignores any remaining days that don't make up a full week.
    • To round up to the nearest week: Use =ROUNDUP((B2-A2)/7, 0). This counts any partial week as a full week.
    • To round to the nearest whole number: Use =ROUND((B2-A2)/7, 0).
  6. Apply to Multiple Rows: If you have a list of dates, click the small green square (fill handle) at the bottom-right corner of your result cell and drag it down to apply the formula to the rest of your data.

Common Mistakes

  • Wrong Date Order: Subtracting the end date from the start date (A2-B2) results in a negative number. Always subtract the earlier date from the later date.
  • Incorrect Cell Formatting: This is the most frequent issue. When you perform math on dates, Excel often automatically formats the result cell as a "Date." If you see a weird date instead of a number, change the format to "General."
  • Text-Based Dates: If your dates are typed as text (e.g., "Oct 12th 2023") rather than standard date formats, Excel cannot perform the subtraction and will return a #VALUE! error.
  • Forgetting Parentheses: Writing =B2-A2/7 without parentheses will cause Excel to divide A2 by 7 first (following the order of operations) and then subtract that result from B2, giving you a massive, incorrect number.

Tips

  • Using TODAY(): If you want to calculate the weeks between a past date and today's date automatically, use the formula =(TODAY()-A2)/7. The result will update every time you open the spreadsheet.
  • DATEDIF Function: For those who prefer specific functions, you can use =DATEDIF(A2, B2, "d")/7. The "d" tells Excel to find the difference in days, which you then divide by 7.
  • Adding Labels: To make your sheet clearer, you can combine the formula with text. Use =ROUND((B2-A2)/7, 0) & " Weeks" to display the result as "5 Weeks" instead of just "5".

Troubleshooting

If your formula is not working as expected, try these steps in order:

  1. Check for #VALUE! Errors: This usually means one of your dates is not actually a date, but text. Try re-typing the date or using the "Data > Text to Columns" tool to convert the column to Date format.
  2. Check the Format: If the number looks like a date or a percentage, go to the Home tab and change the number format dropdown to General.
  3. Verify Parentheses: Double-check that your subtraction is enclosed in parentheses: (End-Start)/7.
  4. Check for Hidden Spaces: Sometimes dates imported from other software have leading or trailing spaces. Use the =TRIM() function to clean the cells if you suspect this is the case.

Frequently Asked Questions

Can I calculate only business weeks?

Excel does not have a "business week" unit. To calculate weeks based on working days, use =NETWORKDAYS(A2, B2)/5. This calculates the number of working days and divides them by the 5-day work week.

Why is my result showing as a date like 1/05/1900?

Excel sees the result of your formula as a number. Because the source cells were dates, Excel assumes the answer should also be a date. Change the cell format to "General" or "Number" via the Home tab to see the actual count of weeks.

How do I include the start date in the count?

Standard subtraction calculates the difference between two points. If you want to include the starting day as part of the first week, add 1 to your subtraction: =(B2-A2+1)/7.

Does this work for dates in different years?

Yes. Excel's date system tracks the total number of days since January 1, 1900, so it automatically accounts for leap years and year transitions.

Can I use this to find the number of weeks until a deadline?

Yes. Put your deadline date in cell B2 and use the formula =(B2-TODAY())/7. This will give you a countdown of weeks remaining until that date.