Stand with Ukraine 🇺🇦
Products
Services
Blog
About Us

Limitations

General Limitations

When working with user macros in Confluence Cloud, it's important to understand their inherent limitations. These constraints impact how macros function, interact with the page, and retrieve data.

1. Macro Execution Limits

2. Execution Environment

Macros operate in two different execution contexts, each with its own restrictions:

  • Dynamic Content Macros:

    • Run inside a sandboxed iframe within the Confluence page.

    • Have no access to the main Confluence DOM and JavaScript environment.

    • Cannot directly manipulate or read the parent page's content outside of what is explicitly passed to the macro.

  • Static Content Macros:

    • Render directly within the Confluence page but come with even more limitations than iframe-based dynamic macros.

    • Styling and formatting options are highly restricted.

    • Interactive elements, such as JavaScript-driven features, won’t function.

3. Limited System Access

User macros don’t have direct access to:

  • The Confluence application internals, including Java APIs.

  • The database or any other server-side storage.

  • The file system on the Confluence server.

4. Data Access Through REST API

The only available data channel for user macros is the Confluence REST API. This means:

  • User macros can retrieve data only through API calls.

  • Any functionality beyond what the REST API provides is not possible within user macros.


Velocity Contexts in Confluence

No Velocity template contexts, such as the default context, are provided out of the box.

Please refer to the developer documentation to learn more.


Dynamic Content Macros

  • Dynamic macros do not support nested macros.

  • Sandboxed iframe isolation:

    • Since dynamic macros run inside an iframe, they cannot interact with elements outside of it.

    • For instance, it’s not possible to:

      • Hide or modify Confluence's global elements, such as the footer.

      • Reorder menu items in the left navigation panel.

      • Inject scripts that affect the main Confluence page.

(info) For a detailed comparison of static and dynamic macros, please refer to this page.

Styling Limitations

  • CSS inside an iframe cannot modify the parent page’s styles.

  • For instance, it’s not possible to:

    • Hide Confluence comments.

      #comments-section {
        display: none;
      }
    • Change the title color.

      #title-text {
        color: red;
      }
    • Modify the appearance of any page content outside the iframe.


Static Content Macros

Static macros are embedded directly into the Confluence page rather than running inside an iframe. While they are not isolated like dynamic macros, they come with even stricter limitations.

1. JavaScript Limitations

  • No JavaScript execution is allowed.

  • No AUI (Atlassian UI library) support, including AJS.

2. Styling Limitations

  • No <style> tags: Only inline styles (style="...") are permitted.

  • Limited styling options: display: flex and display: grid will be removed by Atlassian and won’t be included in the final page code.

(info) Styling details and examples for dynamic & static macros are available on this page.

3. Nested Macros Support

{"timestamp":1792799680259,"msg":"A unknown Exception Occurred","errorMsg":"The provided AtlassianHostUser did not specify a user to act as.","code":"500"}