Available from version 1.14.0
Removed in version 1.32.0 (Gerrit change 463881)
Called when building sql query for Special:Watchlist
Define function:
public static function onSpecialWatchlistQuery( array &$conds, array &$tables, array &$joinConds, array &$fields, FormOptions $opts ) { ... }
Attach hook: In extension.json:
	"Hooks": {
		"SpecialWatchlistQuery": "MediaWiki\\Extension\\MyExtension\\Hooks::onSpecialWatchlistQuery"
Called from: File(s): specials/SpecialWatchlist.php
Interface: SpecialWatchlistQueryHook.php

For more information about attaching hooks, see Manual:Hooks .
For examples of extensions using this hook, see Category:SpecialWatchlistQuery extensions.


  • &$conds: array of WHERE conditionals for query
  • &$tables: array of tables to be queried
  • &$joinConds: JOIN conditions for the tables
  • &$fields: array of query fields
  • $opts: FormOptions