I clock my time in org-mode. Because projects in my line of work can last for several years, I'd like clock reports that extend over a long period of time.

The problem is that it's annoying to keep completed subtasks in my todo files. I'd like to be able to put those in the archive. However, this destroys the clocktable structure. Anything in the archive is listed separately (it's a different file), and there's no longer any hierarchical structure to it.

What I would like is to be able to automagically merge information from the archive and the main file when the clocktable is compiled.

  • I also find this quite odd behaviour. Here's a blog post that describes a way to rebuild a hierarchical tree from an archive file: fuco1.github.io/…
    – ngm
    Commented Nov 13, 2019 at 17:31
  • Err.. I misread the post I linked somehow - what it does is mimic the hierarchy at the point of archiving.
    – ngm
    Commented Nov 13, 2019 at 17:43

1 Answer 1


org-clocktable-defaults can be configured to have :scope set to agenda-with-archives and then archived entries should also be included in clock-table.

The documentation mentions possible values for the :scope field: https://orgmode.org/manual/The-clock-table.html

  • 1
    Do you mean archived in place, or archived in a separate archive file. The former is really messy. But the latter destroys the subtask structure.
    – hartshoj
    Commented Mar 26, 2019 at 22:14
  • Using :scope set to either agenda-with-archives or file-with-archives yields an empty clock table for me, as if those parameter values corrupt the table generation. I'd ultimately like to be able to aggregate the archive and main file times in the clock table per the OP, but for starters, I can't even get my archive file times to show. Is this a known bug? org-archive-location is set to the default value: %s_archive::.
    – kgo
    Commented May 29, 2019 at 17:23
  • 1
    @kgo - agenda-with-archives and file-with-archives both produce a clocktable for me - though, with the same problem as raised by the OP.
    – ngm
    Commented Nov 13, 2019 at 17:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.