From MediaWiki.org
Jump to navigation Jump to search

Lists pages that link to a given page, similar to Special:Whatlinkshere.


  • bltitle: List pages linking to this title. The title does not need to exist.
  • blpageid: Page ID to search.
  • blnamespace: Only list pages in these namespaces
  • blfilterredir: How to filter redirects. (Default: all)
    • all: List all pages regardless of their redirect flag.
    • redirects: Only list redirects. Note that redirects which include links to the page below the redirect itself will also be included in the results. Use API:Redirects to limit the results to only those pages that redirect directly to the source page.
    • nonredirects: Don't list redirects.
  • bllimit: Maximum amount of pages to list. Maximum limit is halved if blredirect is set. No more than 500 (5000 for bots) allowed. (Default: 10)
  • blredirect: If set, pages linking to bltitle through a redirect will also be listed. See below for more detailed information.
  • blcontinue: Used to continue a previous request.


Find all redirect pages that link or redirect to the en:Main Page.

Other links[edit]

Links through redirects[edit]

MediaWiki version: 1.12

When the blredirect parameter is set, this module behaves slightly differently. bllimit applies to both levels separately: if e.g. bllimit=10, at most 10 first-level pages (pages that link to bltitle) and 10 second-level pages (pages that link to bltitle through a redirect) will be listed. Continuing queries also works differently, as displayed in the following example.

Get a list of pages linking to Albert Einstein (note: the initial query includes a "blcontinue" parameter for purposes of illustration)

When continuing this request, we see that there are more pages linking to Einstein, and that some of the other first-level pages are listed again. If we continue this query again, the same first-level pages will be listed in the next response, as well. To progress beyond Energy, we have to query-continue again and again until we've had all links to Einstein (or increase bllimit, of course).

Continuing the previous request:

Links through transclusions[edit]

If you need to list pages as they appear in "What links here" on the MediaWiki sites with pages transcluding the desired page, you might want to try API:Embeddedin list.

Links through image usage[edit]

If you need to list pages as they appear in "What links here" on the MediaWiki sites with pages displaying the desired file, you might want to try API:Imageusage list. This also works on non-existent files.

Error Codes[edit]

Code Info
blbadcontinue Invalid continue param. You should pass the original value returned by the previous query.