Attendance Sheet in Excel with In Time and Out Time (Free Template)

Excel attendance sheet with in time, out time, hours worked and status columns

An attendance sheet in Excel with in time and out time needs three formulas: hours worked as out time minus in time, a late mark when in time is after shift start plus grace, and a status of Present, Half day or Absent. This guide shows each formula, worked dummy data and a free template.

Most small teams still track attendance on a sheet. The common problem is that the sheet only holds P and A, so late arrivals, short days and overtime never show up. Adding in time and out time fixes that, because every other number can be calculated from those two columns. Below is the full setup, with 60 dummy rows for 6 people across 10 working days. If you only need a monthly P/A grid, see our attendance sheet in Excel with formula guide first.

Key takeaways

  • Hours worked = ROUND(MOD(out time – in time, 1) * 24, 2). The MOD makes night shifts work.
  • A late mark is given only when in time is later than shift start plus the grace minutes.
  • Status comes from hours: 8 or more is Present, 4 to under 8 is Half day, less than 4 is Absent. Both limits sit on a Settings sheet.
  • In the sample, the 6 dummy employees log 454.75 hours, with 51 Present, 4 Half day and 5 Absent days.
  • COUNTIFS and SUMIFS build the summary, so no macros are needed.

In this guide

The columns you need

Keep the log in one flat table, one row per employee per day. Do not use a wide grid with a column for each date, because formulas on a flat table are shorter and you can filter or pivot it later.

ColumnTypeExample
DateInput02-Nov-2026
EmployeeInputAmit Verma
In timeInput (hh:mm)09:42
Out timeInput (hh:mm)18:35
Hours workedFormula8.88
Late by (min)Formula12
StatusFormulaPresent
Seven columns are enough. Only the first four are typed.

Type times as hh:mm, for example 09:42. Excel stores a time as a fraction of a day, which is why the formulas below multiply by 24 or 1440. If your biometric export gives times as text, convert them with Data, Text to Columns before using the sheet.

Set the shift rules on a Settings sheet

Never type 9:30 or 8 inside a formula. Put the rules in cells so you can change them in one place when the policy changes. The template uses five inputs on the Settings sheet.

SettingSample valueUsed for
Shift start time09:30Late mark
Shift end time18:30Reference only
Grace period10 minutesLate mark
Hours for Present8.0Status
Hours for Half day4.0Status

The three formulas

Assume In time is in column C, Out time in column D, and the Settings values are in B4 to B8. In row 4 the formulas are:

Hours worked (E4):
=IF(OR(C4="",D4=""),0,ROUND(MOD(D4-C4,1)*24,2))

Late by minutes (F4):
=IF(C4="",0,IF(ROUND((C4-Settings!$B$4)*1440,0)>Settings!$B$6,ROUND((C4-Settings!$B$4)*1440,0),0))

Status (G4):
=IF(E4>=Settings!$B$7,"Present",IF(E4>=Settings!$B$8,"Half day","Absent"))

The hours formula returns 0 when either punch is missing, so a blank row becomes Absent. The late formula converts the gap between in time and shift start to minutes and returns it only when it is more than the grace period. For example, with a 09:30 start and 10 minutes grace, an in time of 09:38 is not late, while 09:42 is late by 12 minutes.

Why MOD? If someone clocks in at 22:00 and out at 06:00, out minus in is negative. MOD(value, 1) turns that into the positive fraction of a day, so the night shift correctly shows 8 hours.

Build it step by step

Step 1: create the three sheets

Add sheets named Settings, Attendance and Summary. Fill the five settings first so the formulas have something to point to.

Step 2: enter the log

On the Attendance sheet, put headings in row 3 and start data in row 4. Format the date column as dd-mmm-yyyy and the two time columns as hh:mm so that 9:42 shows as 09:42.

Step 3: add the formulas and copy them down

Type the three formulas in row 4, select E4 to G4 and drag the fill handle down. Because the Settings cells use absolute references such as $B$4, they do not move when you copy.

Step 4: summarise with COUNTIFS and SUMIFS

On the Summary sheet, list each employee once. Count the statuses with COUNTIFS and add hours with SUMIFS:

Present days : =COUNTIFS(Attendance!$B$4:$B$200,$A4,Attendance!$G$4:$G$200,"Present")
Late marks   : =COUNTIFS(Attendance!$B$4:$B$200,$A4,Attendance!$F$4:$F$200,">0")
Total hours  : =SUMIFS(Attendance!$E$4:$E$200,Attendance!$B$4:$B$200,$A4)
Attendance % : =IFERROR((B4+C4*0.5)/(B4+C4+D4),0)

Use a range that goes beyond your last row, such as row 200, so new rows are counted without editing the formula. The attendance percentage here counts a half day as 0.5 of a day; change the weight if your policy differs.

Reading the sample numbers

The dummy log has 60 rows for 6 employees over 10 working days, from 02-Nov-2026 to 13-Nov-2026. These numbers are made up to show the method, not benchmarks.

EmployeePresentHalf dayAbsentLate marksTotal hours
Amit Verma901477.25
Neha Kulkarni901576.75
Rohan Shah532056.75
Sana Khan901378.25
Vikram Patil1000284.0
Priya Nair910281.75
Total514516454.75
Result of the template on the sample data

Neha Kulkarni has the most late marks, 5, so that is where a conversation would start in a real team. The total row is a useful check: Present, Half day and Absent days add up to 60, which equals 6 employees times 10 days. If that total does not match, a row is missing or has a typo in the employee name.

Summary sheet of the attendance template showing present, half day, absent, late marks and hours per employee
Summary sheet of the free attendance template, built from dummy data

Free attendance sheet template (download)

The workbook has a Settings sheet, the Attendance log with formulas, a Summary sheet and a How to use sheet. It uses no macros and works in Excel 2010 and later.

  • Blue cells are inputs, grey cells are formulas.
  • Replace the dummy rows with your own from row 4.
  • Change the shift start, grace and hour limits on Settings.
  • Extend the Summary list with more employees by copying a row down.

Common mistakes

  • Times typed as text. A time like 9.42 or 9:42 AM typed as text will not calculate. Check that the cell is right-aligned.
  • No grace rule. Without a grace period, one minute becomes a late mark and people stop trusting the sheet.
  • Hard-coded limits. Typing 8 inside the formula means changing hundreds of formulas when the policy changes.
  • Counting weekly offs as absent. Only log working days, or add a Day type column and exclude holidays.
  • Duplicate rows. Two punches for the same person and date double the hours. Check with a pivot or COUNTIFS on date and employee.

When to automate it

This sheet is enough for one team. When attendance comes as a daily export from a biometric machine for several branches, or when managers want filters and trends, a dashboard is faster. See our HR analytics dashboard, or tell us about your report and we will build it on your own Excel file, offline. If you also track headcount, our headcount report in Excel guide pairs well with this one.

Frequently asked questions

How do I make an attendance sheet in Excel with in time and out time?

Create columns for date, employee, in time and out time, then add formulas for hours worked, late minutes and status. Hours worked is out time minus in time, multiplied by 24. Put shift start, grace period and hour limits on a Settings sheet so the rules are easy to change.

How do I calculate working hours from in time and out time in Excel?

Subtract the in time from the out time and multiply by 24, for example =ROUND((D4-C4)*24,2). For shifts that cross midnight, use =ROUND(MOD(D4-C4,1)*24,2). Format the time columns as hh:mm and the result as a number with two decimals.

How do I mark late arrival in Excel?

Compare the in time with the shift start plus a grace period. Convert the gap to minutes with (in time – shift start) * 1440 and return it only when it is greater than the grace minutes. Then count late marks with COUNTIFS on the late column for values above zero.

How do I mark half day in Excel based on hours?

Use nested IF on the hours worked: Present when hours are at least the full day limit, Half day when they are at least the half day limit, otherwise Absent. Keep both limits in Settings cells so you can change the policy without editing every formula.

Can I use this attendance sheet for night shifts?

Yes. Use MOD(out time – in time, 1) * 24 for hours worked. This returns the correct positive hours when the out time is after midnight, such as 22:00 to 06:00. The date on the row should be the date the shift started.

Start with the Settings sheet, then add your own rows

An attendance sheet with in time and out time takes one hour to set up and then runs itself. Download the template, put your shift start and grace period on the Settings sheet, paste a week of real punches and check the Summary. Once the rules are right, extend the same sheet for the whole month and use it as the base for salary and overtime.


About the author: Jitendra Rao is the founder of Excel Keys and has spent over 11 years building MIS reports, sales analytics and dashboard automation for banking and finance teams. He builds Excel dashboards that run offline, on your own files. Last updated: 29 November 2026.

Jitendra RaoYou work directly with Jitendra Rao

Let us build yours

Want a custom dashboard like these for your own data?

Tell us the KPIs, table columns, charts and pivot cuts you need. We will design a dashboard around your requirement and send you a clear plan and quote. Connect with us on the channel you prefer.

Message us