Anchor Macro
- Anchor macro as it appears in the editor
- Anchor macro as it appears when viewing a page (it isn't visible).
Add the anchor macro to your page
To add the Anchor macro to a page:
- From the editor toolbar, choose Insert > Other Macros.
- Choose Anchor from the Confluence content category.
- Enter the anchor name - this will form part of your link.
- Choose Insert.
You can then add a link to your macro from this page or another page.
Linking to an anchor
To link to an anchor on the same page:
- Click the Insert Link icon.
- Choose the Advanced tab.
- Enter # followed by your anchor name in the Link field. For example
#top
. - Choose Insert.
You can also link to an anchor on another page. See Anchors for more information on the different link syntax you can use.
Animation: Adding the Anchor macro to a page, then linking to that macro.
Change the macro parameters
Macro parameters are used to change the behaviour of a macro.
To change the macro parameters:
- In the editor, click the macro placeholder and choose Edit.
- Update the parameters as required then choose Insert.
Here's a list of the parameters available in this macro.
Parameter | Default | Description |
---|---|---|
Anchor Name | None | This is the anchor name that you will use when creating the link.
|
Where the parameter name used in Confluence storage format or wikimarkup is different to the label used in the macro browser, it will be listed below in brackets (example
).
Other ways to add this macro
Add this macro as you type
Add this macro using wiki markup
This is useful when you want to add a macro outside the editor, for example as custom content in the sidebar, header or footer of a space.
Macro name: anchor
Macro body: None.
{anchor:here}