Q01
Why convert durations into several units?
Because humans and systems often describe the same interval in different units and formats.
Convert durations across time units
Quick CTA
Enter seconds or a duration string first to convert between numeric and human-readable formats immediately; examples stay in Deep.
Next step workflow
Deep expands pitfalls, recipes, snippets, FAQ, and related tools when you need troubleshooting or deeper follow-through.
Convert durations from numeric values or human strings like 1d 2h 30m into multiple units at once: milliseconds, seconds, minutes, hours, days, and weeks. The tool also outputs a compact human representation and ISO 8601 duration format for API contracts and scheduling payloads. It is useful in backend timeout tuning, analytics interval normalization, and automation window planning. Everything runs client-side.
Q01
Because humans and systems often describe the same interval in different units and formats.
Q02
Only if the parser clearly understands them; ambiguous strings are a common source of mistakes.
Milliseconds
Use it for systems, APIs, and machine-readable config.
Human duration text
Use it for docs, UI labels, and human review.
Note: Machines prefer raw units, while humans prefer structured time phrases.
Human duration text
Use it in docs and handoff notes for readability.
Raw milliseconds
Use it in config files and APIs that require deterministic machine units.
Note: Keep both forms side-by-side when teams collaborate across roles.
Human-readable
Use for docs, product copy, and stakeholder communication.
Machine units (ms/s)
Use for configuration, APIs, and deterministic program behavior.
Note: Use machine units for source-of-truth and render human text at the edges.
Quick output
Use for one-off internal checks with low blast radius.
Validated workflow
Use for production pipelines, audits, or customer-facing output.
Note: Duration converter should be treated as a workflow step, not an isolated click.
Single pass
Use when turnaround time is more important than traceability.
Stage + verify
Use when reproducibility and post-incident replay are required.
Note: A staged path usually prevents silent data-quality regressions.
Bad input: {"timeout": 30000} interpreted as 30,000 seconds by downstream service.
Failure: Jobs stall for hours instead of timing out in 30 seconds.
Fix: Annotate units explicitly and enforce schema validation for duration fields.
Bad input: One service rounds 1.5m to 90s while another truncates to 60s.
Failure: Retry and cache behaviors diverge unexpectedly.
Fix: Standardize rounding rules and convert once at system boundaries.
Bad input: Different dashboards round fractional hours in opposite directions.
Failure: Teams dispute whether incidents breached target windows.
Fix: Define one rounding convention and apply it in all converters/reports.
Bad input: Month-to-day assumptions differ across teams.
Failure: Output looks valid but downstream systems reject or misread it.
Fix: Normalize input format and add a preflight validation step before export.
Bad input: DST boundary is ignored for timezone-sensitive windows.
Failure: Different environments produce inconsistent results from the same source data.
Fix: Document compatibility mode and verify with at least one independent consumer.
Goal: Translate between milliseconds and human-readable duration strings.
Result: You can stop doing repeated time math in your head or in scratch pads.
Goal: Translate human-readable durations into seconds or milliseconds for API and job configs.
Result: Configuration becomes clearer and less error-prone across product, ops, and engineering teams.
Goal: Align mixed unit inputs into comparable duration standards.
Result: SLA reporting stays comparable across products and regions.
Goal: Reduce avoidable rework by validating assumptions before publishing output.
Result: Teams can ship faster with fewer back-and-forth fixes.
Goal: Turn production anomalies into repeatable diagnostic steps.
Result: Recovery time decreases because operators follow a tested path.
Recommend: Keep canonical machine units with explicit field naming.
Avoid: Avoid free-text duration strings as contract primitives.
Recommend: Render human-readable durations derived from canonical units.
Avoid: Avoid exposing raw millisecond numbers without contextual formatting.
Recommend: Normalize units early and publish shared rounding conventions.
Avoid: Avoid mixing unit conversion and business-time assumptions silently.
Recommend: Use quick mode with lightweight validation.
Avoid: Avoid treating ad-hoc output as production truth.
Recommend: Use staged workflow with explicit verification records.
Avoid: Avoid single-pass output without replayable validation logs.
Cause: A loose string can be interpreted differently across tools or people.
Fix: Prefer explicit unit labels and validate the parsed result.
Cause: Different SDKs expect different units, and silent mismatch often causes premature timeout or huge delays.
Fix: Annotate every duration field with explicit units and validate with one end-to-end smoke test.
txt
1d 2h 30m 15sDuration Converter is most reliable with real inputs and scenario-driven decisions, especially around "Programmatic config and interoperability contracts".
Yes. Human mode supports combined tokens such as w, d, h, m, s, and ms.
Yes. ISO 8601 output is included for API and data interchange workflows.
Yes. All supported units are cross-converted from a single normalized base.
This version is focused on non-negative durations for operational safety.
Compact output is easier to read in logs, configs, and CLI summaries.
No. Parsing and conversion are fully local in your browser.