Skip to content

Find pages not updated recently

Find stale or outdated pages that were not updated recently — by last update day count, without needing Confluence Premium Inactive pages for that search. Use find -mtime, then optionally export CSV or mv -n (max 100).

Use GNU-style day filters (+N / -N / N). Age is measured in 24-hour units on last update (content version when), not created date. Spaces never match -mtime (they have no mtime). Results come from the CQL search index and may lag richer ls -l by seconds to minutes right after edits.

Watch on YouTube: youtu.be/RqYSeaZZLbc

$ cd YourSpace
$ find . -mtime +30
$ find ./Projects -mtime +365
$ find . -name '*Notes*' -mtime +180

+30 means older than 31×24 hours; -7 means younger than 7 days; 0 means last 24 hours. Integer N only.

Optional: prune, then dry-run move (max 100)

Section titled “Optional: prune, then dry-run move (max 100)”

To keep top-most matches so a later move does not flatten parent and child, put -prune before piping into mv -n:

$ mkdir ./Archive
$ find ./Projects -mtime +365 -prune | mv -n ./Archive
$ find ./Projects -mtime +365 -prune | head 100 | mv -n ./Archive

Preview with -n / --dry-run first. At most 100 sources per mv (same cap as other piped moves). A move into another space needs -y / --yes.

$ find ./Projects -mtime +365 -prune | label add needs-review -y
$ find ./Projects -mtime +730 -prune | archive -n

See Label stale pages for review and Archive stale pages (Standard or above). To export the list, add --format csv to find.

  • Last update, not created date.
  • Spaces never match -mtime.
  • CQL index may lag ls -l after edits; re-run if a just-edited page still appears stale.
  • Press Esc or Ctrl+C to stop a long find.