Macro options (parameters)
Parameters are options that you can set to control the content or format of the macro output. 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 (
This is the anchor name that you will use when creating the link.
Step 2: Create a link to the anchor
- A page on the same Confluence site. The link may be on the same page as the anchor, another page in the same space, or a page in another space on the same Confluence site.
- Another web page or another Confluence site, using a specifically formatted URL.
Link to an anchor on the same Confluence site:
- Select some text or position your cursor where you want to insert the link
- Choose Link in the toolbar or press Ctrl+K
Choose Advanced and enter the anchor name in the Link field, following the format below.
Anchor location Link syntax for anchor Examples Same page #anchor name
Page in same space page name#anchor name
My page#important information
Page in different space
spacekey:page name#anchor name
DOC:My page#important information
The anchor name is case sensitive, so you need to use the same pattern of upper and lower case letters as you used when creating the Anchor macro. You need to enter page and anchor names with spaces when you link to them in the same Confluence site.
- Enter or modify the Link Text (this is the text that will appear on the page. If this field is left blank, the page name or URL will be used as the link text)
- Choose Save
Screenshot: The 'Advanced' option in the link dialog
Link to an anchor from another web page or another Confluence site:
Use a full URL in the following format:
Notes about the full URL:
- The page name is repeated in the URL, after the # sign. The second occurrence of the page name is concatenated into a single word, with all spaces removed.
- There is a single dash (hyphen) between the concatenated page name and the anchor name.
- The anchor name in the full URL is concatenated into a single word, with all spaces removed.
- The anchor name is case sensitive.
- Table of contents on a page: Consider using the Table of Contents Macro to generate a list of links pointing to the headings on the page. The list of links will appear on the page, and will be automatically updated each time someone changes the wording of a heading.
- Linking to headings: You can link directly to the headings of a page. See Working with Links. However, if someone changes the wording of a heading, those direct links will be broken. Use the Anchor macro to ensure a lasting link within the body of a page.
- Site welcome message: If you are adding an anchor to a page that you are using in the site welcome message, you can only link to that anchor from another page. Internal links within that page will not work.
- Templates: When you are previewing a template, a link to an anchor is displayed as a 'broken' link. However, when you create a page using the template the resulting page will have the correct link.