Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

🔄 Keeping Confluence Content Fresh with Automation

A real-world approach to identifying stale pages, notifying owners, and working around the limitations of Atlassian Cloud automation

As a Confluence Cloud admin, I appreciate the power and flexibility of Confluence, Jira, and Automation for Cloud. However, building automations that seem straightforward can sometimes reveal unexpected complexities. I want to share the automation setup I developed to notify Confluence page owners when their content becomes stale, along with the lessons learned and adjustments made to achieve the desired functionality.


Defining “Stale” Content

Before implementing automation, we established criteria to define outdated content. This content health system guides our expectations and flags pages accordingly:

Health State

Last Updated Within

âś… Healthy

0–6 months

⚠️ Stale

6–12 months

❌ Inactive

12+ months

❓Why Bother With This?

Because a knowledge base is only useful when it’s accurate, relevant, and trusted:

  • Accuracy prevents bad information from spreading.

  • Relevance ensures your content reflects the tools and processes today—not three years ago.

  • Trustworthiness shows users you care about quality and reliability.

This small effort pays off in a big way: fewer support tickets, better onboarding, and a more empowered workforce.


How the Automation Works

On the last day of every month at 9:00 AM, an automation runs that:

  1. Identifies all pages not updated in 6+ months

  2. Groups them by owner using {{pagesPerOwner}}

  3. Sends each owner a personalized email listing their pages

  4. Adds the label needs-review to each stale page

  5. When an owner edits their page, a second automation removes the label

This cycle continues monthly until the page is updated.


⚙️ Automation Setup: Step-by-Step

Primary Automation – Email + Labeling

  • Trigger: Scheduled (Monthly)

  • Branch: For pages last updated more than 6 months ago

  • Then Branch: For each page in {{pagesPerOwner}}, variable name: ownerStalePages

  • If Condition:

    • {{ownerStalePages.first().owner.emailAddress}}

    • Condition: Does not equal

    • Value: Empty

  • Then:

    • Send Email To: {{ownerStalePages.owner.emailAddress}}

    • Subject: (Your choice)

    • Content: Includes HTML table listing pages (see below)

    • If: {{page.labels}} does not contain needs-review

    • Then: Add label needs-review

Secondary Automation – Label Cleanup

  • Trigger: When a page is edited

  • If: {{page.labels}} contains needs-review

  • Then: Remove label needs-review

 

If you are new to Automation, a quick tip here. Whatever you make the variable is up to you. I chose ownerStalePages. However, whatever you choose here is case sensitive, and you will need to type it exactly the same in the other places.
ie: {{ownerStalePages.owner.emailAddress}}

If this was {{OwnerStalePages.owner.emailAddress}} instead it would not function properly because the O is capital and not lowercase.


🔄 Important: How to List Multiple Pages in an Email

One key thing to know—if you want to display a list of multiple pages (or items) in an email, you need to use this structure:

{{#smartValue}} … content you want repeated … {{/}}

This tells Confluence Automation to repeat whatever is inside those brackets for each item in the list. Think of it like saying,

“For every page this person owns, show me a row with the page info.”

In my automation, I used this with the pagesPerOwner smart value, like this:

{{#ownerStalePages}} … details for each page here … {{/}}

Without this, your email would only show a single page (or nothing at all).
With it, you can build dynamic tables, bulleted lists, etc., that include every page needing review.

This isn’t always well-documented, so it’s a good trick to keep in mind for any smart value that returns more than one result.


✉️ Enhancing Email Readability with HTML

Default Automation emails are plain text, which can be hard to read. To improve clarity, I used HTML to structure the message and page list:

 

<p>These pages haven’t been updated for a while. Please review them to determine if they need updating or should be archived.
</p>

<table style="width:100%; border-collapse:collapse;
font-family:Arial, sans-serif; font-size:14px;
border:1px solid #dfe1e6;">
<tr style="background:#f4f5f7; color:#172b4d; line-height:1.2;">
<th style="text-align:left; padding:6px 10px; border-bottom:1px solid #dfe1e6;">Page</th>
<th style="text-align:left; padding:6px 10px; border-bottom:1px solid #dfe1e6;">Space</th>
<th style="text-align:left; padding:6px 10px; border-bottom:1px solid #dfe1e6;">Last Updated</th>
</tr>
{{#ownerStalePages}}
<tr style="line-height:1.2;">
<td style="padding:6px 10px; border-bottom:1px solid #dfe1e6;">
<a href="{{url}}" style="color:#0052cc; text-decoration:none;">{{title}}</a>
</td>
<td style="padding:6px 10px; border-bottom:1px solid #dfe1e6;">{{dateLastUpdated.shortDate}}</td>
</tr>
{{/}}
</table>

<p style="margin-top:16px;"> For more details on page health expectations, see: <a href="LINK_TO_DOC">this page</a>.
</p>

đź’ˇ Replace "LINK_TO_DOC" with your actual documentation link.


đź§  Advanced Use Cases

đźš« Avoiding Page Status Changes

Initially, I considered updating a page's status to “Needs Review” when it became stale. However:

âť— Changing the status counts as an edit, updating the last modified timestamp.
This resets the automation tracking and removes the page from future notifications—even if no substantial content was changed.

To maintain accurate tracking, I opted to use labels instead.


đź§© Creating Jira Work Items Instead of Sending Emails

For teams that prefer managing tasks within Jira, I developed an alternative automation:

  • Trigger: Scheduled (same as above)

  • Then: Create a new work item in their Jira project

  • Summary: Review stale Confluence page: {{title}}

  • Description:

    The page [{{title}}|{{url}}] hasn’t been updated in over 6 months. Please review it and decide if it needs updating or should be archived. Last Updated: {{dateLastUpdated.shortDate}}

This approach integrates content review into the team's existing Jira workflow, facilitating better tracking and prioritization.


⚠️ Potential Pitfalls to Avoid

🚫 “Inactive Pages” Doesn’t Mean What You Think

Misinterpretation of “Inactive” Pages

If you’re trying to build a reminder system based on update activity, ignore the word “inactive” entirely.

According to Atlassian:

“An inactive page is any page that has not been viewed in the specified time period. The view history includes updates and comments.”
— Branches in Confluence automation

This means even a brief view or comment marks a page as active, regardless of content updates. For tracking maintenance, rely on Branch: For pages last updated more than * months ago instead.

đź”’ Inactive Parent Pages Are Ignored

Atlassian's documentation also notes:

“Inactive parent pages are excluded […] as a security measure.”
— Smart values in Confluence automation

Top-level pages may not be included in inactivePages, potentially omitting important content from your automation.


đź§Ż Known Issue: {{space.name}} Smart Value (and Friends) Not Working

In the email table originally I was using {{space.name}} to show which space each page belongs to. Unfortunately, this doesn't currently work—even though it's documented as a supported value.

This is a known issue Atlassian has tracked under this bug report:
đź”— CONFCLOUD-79794 Smart Values for spaces are not working on Confluence Automation

📅 This bug has been open since February 2023, but as of today, the official documentation still lists space.name and many other space properties as functional—even though they are not.

đź“„ Documentation That Needs Updating

Atlassian’s documentation here still shows the following space properties as available smart values:
🔗 Smart values in Confluence automation – Space properties

Property

Description

{{space.url}}

Link to the space overview

{{space.id}}

Unique ID of the space

{{space.key}}

Unique space key (URL identifier)

{{space.name}}

Name of the space

{{space.isPersonal}}

Boolean: is it a personal space?

{{space.creator}}

Full creator object with sub-properties:

{{space.creator.accountId}}

Account ID of creator

{{space.creator.emailAddress}}

Email of creator

{{space.creator.fullName}}

Full name of creator

{{space.creator.publicName}}

Public name (Community profile)

{{space.creator.timeZone}}

Time zone of creator

In reality, none of these space-related smart values currently work in Automation for Confluence Cloud. If you're seeing blank fields in your emails or automation actions, this is why.

📝 What to Do Instead:

For now, consider removing space-specific data from your email templates and focusing on page-level details (like title, URL, and last updated date). Alternatively, I created a separate Automation for each space, Its not a good work-around, but it is what we are left with at the moment.


✉️ Understanding Batched Email Notifications

Implementing batched email notifications in Confluence automation can streamline communication. Atlassian introduced batch notifications and lookup capabilities to enhance automated emails, allowing multiple notifications to be grouped into a single email.

For detailed guidance on setting up batched email notifications, refer to Atlassian's documentation: New batch notifications and look-up capabilities.


đź’¬ Final Thoughts

Atlassian provides powerful tools, but navigating automation requires careful consideration. I hope this breakdown assists others in implementing effective content review processes.

If you're working on similar initiatives, feel free to connect—I'm always open to exchanging ideas with fellow admins striving to enhance Confluence for their teams.

12 comments

Jonathan Smith
Contributor
May 16, 2025

This is a great post! I'll need to review the batched email notification settings to confirm users won't get 1 email per inactive page.

Thanks,

Jonathan

Like • # people like this
Guess_ Brandi N_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 16, 2025

@Jonathan Smith  absolutely. The multiple emails was the number one complaint I got from my colleagues when I started all of this.  Some of our users own hundreds of pages, they don't have time to sift through that many emails. 

Like • Miriam Hopton likes this
Stavros_Rougas_EasyApps
Atlassian Partner
May 16, 2025

@Guess_ Brandi N_ this is a smart we thought out post. I'm going to share it on our LinkedIn company page.

Re updating statuses, you wrote automation does not work. We recently added a status manager to Space Content Manager, you can bulk update page status.

Like • Guess_ Brandi N_ likes this
Guess_ Brandi N_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 16, 2025

@Stavros_Rougas_EasyApps

Hey, thank you so much for reading and for sharing—it means a lot! I know it’s a bit of a deep dive, but my goal was to save others from the same headaches by putting everything in one place.

Regarding page statuses: Automation does work for updating them. The challenge I ran into is that changing a page’s status also updates the “last updated” timestamp—which makes it look like the content was reviewed or edited, even if no actual content was touched. For content health tracking, that skews the results.

I’m really hoping Atlassian rethinks this behavior. Ideally, status changes (like labels) wouldn’t update the page history—only meaningful content edits should trigger that.

Thanks again for the thoughtful comment! 🙌



Like • # people like this
Stavros_Rougas_EasyApps
Atlassian Partner
May 16, 2025

@Guess_ Brandi N_ ok got it, hopefully Atlassian updates that changing a page’s status also updates the “last updated” timestamp. But I would not expect it too soon, not exactly top priority I imagine.

Debbie Jolley
Contributor
May 19, 2025

This is a great post with lots of really useful information.
Thank you for taking the time to compile this and share with the community.

If I ever get some decent breathing space I may look to implement some of this in our instance.

One question - what does this Automation rule do if you have pages Owned by inactive users? - or do you run an Automation to identify/update those to ensure it doesn't happen?

Like • Guess_ Brandi N_ likes this
Guess_ Brandi N_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 19, 2025

@Debbie Jolley I am in a unique position, that I get to do confluence 40 hours a week, for a relatively small ammount of users. So I move pages from inactive users as they leave. 

 

If I couldn't always do that I would use an automation to handle those 

Like • Debbie Jolley likes this
Tami Dubi
Contributor
May 20, 2025

Hi @Guess_ Brandi N_ ,
Thanks for sharing this valuable knowledge. 
As you said, it is important to establish the framework and definition before starting.

1. Regarding not using Confluence Statuses, I agree. Moreover, besides updating the dates, the last updated by is also affected, showing the person who created the rule, which is unacceptable since it hinders the understanding of who the expert, knowledgeable person of the content is.

2. Do you also rule out different types of pages (established by labels) that shouldn't be updated, like meeting notes, release notes, etc? In which phase do you recommend putting it in the flow?

3. I would be careful with the automation of page ownership since it's something that needs to be established first as part of the KRT (knowledge retention and transfer) of an employee's managers in the offboarding process, as page ownership is connected to organizational responsibility. The automation could be manually triggered after achieving an understanding of the replacement. 
Thanks again, 
Tami

Hua Soon SIM _Akeles_
Atlassian Partner
May 24, 2025

Thanks @Guess_ Brandi N_ for sharing. 
Your post got me interested and I tried to set it up on our Confluence. 

Did I get it correct?

Screenshot 2025-05-24 at 3.44.37 PM.png

Guess_ Brandi N_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2025

@Tami Dubi thanks for the well thought out comment. 

Yes I do use labels to rule out pages that won't need updated. These are most often pages using the insert page macro, because the content is being updated from the originating source.  

 

We dont use automation to update the ownership of a page. At the moment I work with whomever is needed to determine where a page needs to go if someone leaves. We're small and that doesn't happen often.

 

 

Guess_ Brandi N_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 24, 2025

@Hua Soon SIM _Akeles_  looks good but without seeing individual ones, like what's in the email, and what's in the page branch I cannot be sure.

Hua Soon SIM _Akeles_
Atlassian Partner
May 25, 2025

Thanks.
After playing with it, I think there should be 2 branches


 Screenshot 2025-05-25 at 5.00.40 PM.png

I have also added screenshots of the individual components.

 

  • Trigger: Scheduled (Monthly)Screenshot 2025-05-25 at 5.00.51 PM.png

  • Branch: For pages last updated more than 6 months agoScreenshot 2025-05-25 at 5.01.02 PM.png

  • Then Branch: For each page in {{pagesPerOwner}}, variable name: ownerStalePagesScreenshot 2025-05-25 at 5.01.09 PM.png

  • If Condition:

    • {{ownerStalePages.first().owner.emailAddress}}

    • Condition: Does not equal

    • Value: Empty
      Screenshot 2025-05-25 at 5.01.16 PM.png

  • Then:

    • Send Email To: {{ownerStalePages.owner.emailAddress}}

    • Subject: (Your choice)

    • Content: Includes HTML table listing pages (see below)
      Screenshot 2025-05-25 at 5.05.56 PM.png

    • If: {{page.labels}} does not contain needs-review
      Screenshot 2025-05-25 at 5.06.28 PM.png

    • Then: Add label needs-review
      Screenshot 2025-05-25 at 5.06.37 PM.png
       
      This one will throw a validation warning

Not sure I got it correct?

Comment

Log in or Sign up to comment
TAGS
AUG Leaders

Atlassian Community Events