# Time Converter: Seconds, Hours, Days, Months, Years and Decimal Hours

Page: https://hirantha.me/tools/time-converter
Part of: Hirantha Sandaruwan Lakshan free tools (https://hirantha.me/tools)
Updated: 2026-10-13

Convert seconds, minutes, hours, days, weeks, months and years with the month and year lengths stated, plus hh:mm to decimal hours for timesheets.

This is a free tool that runs in the browser: open the page to use it. File tools process files on the visitor's own device; files are never uploaded or stored. No account, sign-up, payment or watermark.

Convert any length of time between microseconds and years, with the month and year lengths stated so the answer is not a guess. Three helpers cover timesheets: hours and minutes (7:45) to decimal hours (7.75), decimal hours back to hours and minutes, and minutes to hours and minutes. Sums are done in whole seconds, so nothing drifts, and nothing you type leaves your device.

Seconds are the base. A minute is 60 seconds, an hour is 3,600 seconds and a day is 86,400 seconds; NIST lists the minute, hour and day among the units accepted for use with the SI. A week is seven days, which is 604,800 seconds. Leap seconds are ignored, so a day here is always exactly 86,400 seconds. The tool converts lengths of time, not clock times, so daylight saving does not come into it.

Months and years are not fixed, so the tool lists the choices. The average Gregorian year is 365.2425 days: a 400-year cycle holds 97 leap years, so it has 303 x 365 + 97 x 366 = 146,097 days, and 146,097 divided by 400 is 365.2425. The average Gregorian month is 365.2425 divided by 12 = 30.436875 days, which is 2,629,746 seconds. Many payrolls and contracts use a 30-day month or a 365-day year instead (NIST lists a 365-day year as 3.1536 x 10^7 seconds, which is 365 x 86,400 = 31,536,000), so both are in the list too. A real calendar month is 28 to 31 days; for the exact gap between two dates use the date difference calculator.

Timesheets often need decimal hours: 7.75 instead of 7:45. Divide the minutes by 60. 45 minutes is 0.75 hours, so 7:45 is 7.75 hours. 20 minutes is 0.3333 hours, so 8:20 is 8.3333 hours. When you enter several times the tool adds them in whole seconds and rounds once at the end, so three shifts of 8:20 add up to exactly 25:00, which is 25 hours, where three rounded lines of 8.33 would give 24.99. Rounding rules such as the nearest quarter hour are an employer or payroll decision, so check yours.

The reverse helpers work the same way. Multiply the decimal part of an hour by 60 to get minutes: 0.6 hours is 36 minutes, so 2.6 hours is 2:36:00. A value that is not a whole number of seconds is rounded to the nearest second, and the page tells you when that happens. Minutes to hours and minutes divides by 60 and keeps the remainder: 135 minutes is 2 h 15 min, and 135.5 minutes is 2 h 15 min 30 s.

Seconds in common periods:
| Period | Seconds | How |
| --- | --- | --- |
| 1 minute | 60 | 60 seconds |
| 1 hour | 3,600 | 60 minutes |
| 1 day | 86,400 | 24 hours |
| 1 week | 604,800 | 7 days |
| 1 month of 30 days | 2,592,000 | 30 days |
| 1 average Gregorian month | 2,629,746 | 365.2425 days divided by 12 = 30.436875 days |
| 1 year of 365 days | 31,536,000 | 365 days |
| 1 leap year of 366 days | 31,622,400 | 366 days |
| 1 average Gregorian year | 31,556,952 | 365.2425 days (97 leap years in 400 years) |

Q: How do I convert hh:mm to decimal hours?
A: Divide the minutes by 60 and add the hours. 7:45 is 7 + 45/60 = 7.75 hours and 8:20 is 8 + 20/60 = 8.3333 hours. To include seconds, divide them by 3,600.

Q: How do I convert decimal hours to hours and minutes?
A: Keep the whole number as hours and multiply the decimal part by 60 for minutes. 2.6 hours is 2 hours and 0.6 x 60 = 36 minutes, so 2:36. Common ones: 0.25 is 15 minutes, 0.5 is 30, 0.75 is 45 and 0.1 is 6.

Q: How many seconds are in a day, a year and a month?
A: A day has 86,400 seconds. A 365-day year has 31,536,000 and the average Gregorian year (365.2425 days) has 31,556,952. A 30-day month has 2,592,000 and the average Gregorian month has 2,629,746.

Q: How many days are in a month for conversions?
A: There is no single answer. The average Gregorian month is 30.436875 days, many payrolls use 30 days, and real months run from 28 to 31. Pick the one your contract or system uses. The tool lists both the average month and the 30-day month.

Q: Why do I get 24.99 instead of 25 when I add rounded hours?
A: Because 8:20 is 8.3333... hours, and rounding each line to 8.33 throws away a little every time. Adding in whole seconds and rounding once at the end avoids that, which is how this tool does it.

Q: Does the tool handle daylight saving or time zones?
A: No. It converts lengths of time, not clock times, and a day is always 24 hours. Sri Lanka does not use daylight saving, so this matches a Sri Lankan day. For clock times in different places, use the Colombo time converter.

Q: Can I use this for overtime or payroll?
A: It does the arithmetic of hours and decimals. Pay rules, rounding to a quarter hour and overtime rates depend on your employer and the law. For Sri Lankan overtime use the overtime calculator.

Sources: NIST Guide to the SI, chapter 5: minute (60 s), hour (3600 s) and day (86 400 s) as units accepted for use with the SI, checked 2026-10-13 (https://www.nist.gov/pml/special-publication-811/nist-guide-si-chapter-5-units-outside-si); NIST Guide to the SI, Appendix B.8: year (365 days) = 3.1536 E+07 seconds, checked 2026-10-13 (https://www.nist.gov/pml/special-publication-811/nist-guide-si-appendix-b-conversion-factors/nist-guide-si-appendix-b8); Wikipedia, Gregorian calendar: 400-year cycle of 146,097 days with 97 leap years, average year 365.2425 days, checked 2026-10-13 (https://en.wikipedia.org/wiki/Gregorian_calendar); Claus Tøndering, Calendar FAQ: the Gregorian calendar (97 leap years in 400 years, 365.2425 days), checked 2026-10-13 (https://www.tondering.dk/claus/cal/gregorian.php)

Related tools:

- [Overtime pay calculator (Sri Lanka)](https://hirantha.me/tools/overtime-calculator.md): Overtime pay for shop and office employees from monthly, daily or hourly pay: 1.5 times the hourly rate, monthly pay divided by 240, both editable.
- [Salary to hourly rate calculator](https://hirantha.me/tools/salary-to-hourly-calculator.md): Turn a monthly, weekly, daily, hourly or yearly pay figure into every other rate, with your own hours per week and weeks per year.
- [Days between two dates calculator](https://hirantha.me/tools/date-difference-calculator.md): Count the days between two dates in weeks, months and years, with business days, an end-date option and Sri Lanka holidays left out if you like.
- [Colombo time converter (Sri Lanka time)](https://hirantha.me/tools/colombo-time-converter.md): Convert Sri Lanka time (Colombo, UTC+5:30) to London, New York, Dubai, Singapore, Sydney and more, with the day change and shared working hours.
- [Speed converter: km/h, mph, knots, m/s and Mach](https://hirantha.me/tools/speed-converter.md): Convert km/h, mph, knots, m/s, ft/s and Mach in one go. Every factor is exact, and Mach uses a stated speed of sound that you can change.
