The Highlight macro changes the background color of a section of content. This is useful for small amounts of content such as a word, heading, or single sentence. To highlight larger blocks of text, use the Background Color macro.
Navigate to the page you want to edit.
- Select the text you want to high, or click the position where you want to add highlighted text.
Click Insert More Content > Other Macros.
Select the Highlight macro from the Macro Browser.
Define the color to apply. If you have selected text in step 3, it is displayed in the preview panel of the macro editor.
Specify the color to be used. This can be either a common color name (supported by most browsers) or a hexadecimal color code (supported by all browsers).
There are several special pastel colors: yellow (default), red, blue, cyan, green and purple.
Option to apply a custom CSS class to the element. Enter the CSS class name(s) to apply to the macro (case sensitive); multiple classes can be separated by a space or comma. Do not include the
.selector in the class name. Classes must be part of your Global Confluence CSS or defined in a CSS Stylesheet macro that you have added to your page.
Click Insert. The macro placeholder displays. If you haven't already selected the text to highlight, enter the required content.
Save the page to render the highlighted text.
There are several built-in pastel colors ideal for use as backgrounds which can be set as follows:
Color parameter set to
red, yellow, green, cyan, blue and
With Color parameter set to
Hexadecimal color code
To ensure a precise color is applied, use a hexadecimal color code, e.g.
. My notes.
Try to keep a contrast between the text and the background, so that it is still clearly readable.
Frequently Asked Questions
Q: Can I highlight an entire block of content?
A: Yes. The Background Color macro is better suited in this case.
Q: I’m using hexadecimal codes, but they are not working - why?
A:This macro requires that "#" is included at the start of the code.
Q: Where can I get HTML text color codes?
Q: Some color names, such as "grey", don’t seem to work in all browsers - why?
A: Color names are supported differently by different browsers. To be 100% sure of getting the right color, use the hexadecimal color code instead.
Q: How do I change the color of text?
A: Use Confluence's text formatting tools found on the toolbar.
Q: How do I change the default background color of my page, etc?
A: If using a standard theme, there are some limited options to change colors. If using the Builder theme, complete control over all colors are provided using Custom CSS Styles.
Q: Can I put a graphic in the background?
A: Yes. Span Tag and Style Sheet enable more formatting to your content.