URL Configuration Properties

Last modified by Eleni Cojocariu on 2026/10/30 22:33

Reference

The configuration keys that decide which URLs XWiki accepts and which URLs it generates. The How-tos under Short URLs are what set them.

Two files are involved, and they do not do the same thing. The xwiki.cfg keys are what XWiki's URL factory reads when it generates a URL. The url.standard.* keys of xwiki.properties only affect how an incoming URL is read, so setting one of them changes nothing about the URLs the wiki puts in its pages.

PropertyFileDefaultWhat it does
xwiki.webapppathxwiki.cfgtaken from the request URLThe application name used in generated URLs. An empty value removes it.
xwiki.servletpathxwiki.cfgtaken from the request URLA hard override of the servlet mapping in generated URLs, written with a trailing slash and no leading one. A short-URL setup uses xwiki.defaultservletpath instead.
xwiki.defaultservletpathxwiki.cfgbin/The fallback servlet mapping, used when it cannot be determined from the request URL, which is the case behind a reverse proxy. An empty value drops bin from generated URLs.
url.standard.entityPathPrefixxwiki.propertiesbinThe prefix XWiki recognises as introducing an entity path when it reads an incoming URL. It does not change the URLs XWiki generates: xwiki.defaultservletpath does that.
xwiki.showviewactionxwiki.cfg1Whether the view action appears in generated URLs. Set it to 0 to omit it.
url.standard.hideViewActionxwiki.propertiesfalseDeclared in xwiki.properties as the replacement for xwiki.showviewaction, but no code reads its value, so setting it has no effect.
url.standard.multiwiki.wikiPathPrefixxwiki.propertieswikiThe path segment that precedes the name of a path-based subwiki. Changing it means changing the matching action servlet mapping in web.xml too.

FAQ

Which value wins if I set both keys of a pair?

For reading an incoming URL, the xwiki.properties one, the xwiki.cfg value serving only as its default. For the URLs XWiki generates, the xwiki.cfg key is the only one consulted.

Is there an xwiki.properties key for the application name?

No. xwiki.webapppath exists only in xwiki.cfg.

Related

Get Connected