Skip to end of metadata
Go to start of metadata


The Search Box macro displays a search box on a page.

This macro offers the right balance between ease of use and flexibility to search specific Confluence spaces for content.


Click Insert > Other Macros.

Select the Search Box macro from the provided list.

Complete the desired fields.




Search a specific space, list of spaces or use keywords to specify spaces @all, @personal, @global, @favourite, @current (default).




Search all spacesOverrides the spaces list above.checkboxunchecked


Filter Last ModifiedFilter the list of spaces by team labels (only the selected space is searched).stringnone(error)
GroupingGroup results by space/type/@select.single selectnone(error)
Filter Last ModifiedFilter list of search results by last modified date (today/yesterday/lastweek/lastmonth/@select).single selectnone(error)
Object TypeOnly return objects of type (page/blogpost/mail/comment/attachment/userinfo.single selectnone(error)
Global Text LabelThe text to use for labeling global searches.stringGlobal Spaces(error)
Personal Spaces LabelThe text to use for labeling personal searches.stringPersonal Spaces(error)
Favourite Spaces LabelThe text to use for labeling global searches.
stringFavourite Spaces(error)
All Spaces LabelThe text to use for labeling global searches.
stringAll Spaces(error)
Search Button LabelSearch Button Label - The text to use for the search button.
Search Input LabelAdds a label to the search input.stringnone(error)
Access KeyAdds an access key to the search button.stringnone(error)
Show ButtonDisplay the search button (true/false).
CSS ClassThe class attribute of the element.stringnone(error)

The macro will then appear on the page.


Search the current Space

Search Box macro added with default parameters.

Which results in:

Search a specific Space

Create a search box to search a specific space as follows:

With Space parameter set to "ADAPTAVIST".

Which results in:

As you can see, there's no visual distinction between this search box and the one in the previous example, so you should indicate on-screen that the search box is searching a different space.

The Space parameter value must be exactly the same as the Space Key in terms of capitalization. In our example above, if we used Adaptavist the search would not work properly.

Specify multiple spaces

Create a search box to search a specific space as follows:

With Space parameter set to "SUP, PROD".

Search all Spaces

Create a search box that searches all spaces as follows:

With Search all spaces checkbox "checked".

Which results in:

Improved Layout

Using a search box on it's own doesn't tell the user what they are searching. Using macros such as the panel macro and Center Content, you can create an improved search panel on your pages:

Default Search Box macro contained in a Center macro within a Panel macro.

Which results in:

Search Panel

Enter search query below to search the current space only.

As you can see, it's much more obvious what is being searched and by centering the search box it looks a nicer on-screen.

Hints and Tips:

The search will only allow a user to search in spaces that they have sufficient privileges to view.

You can use advanced Search Query Syntax within the search box should more specific searching be required.

Frequently Asked Questions:


Can I display search results for a specific query on a page?



Top of page

  • No labels