Extension default namespaces

From MediaWiki.org
Jump to navigation Jump to search

To prevent conflicts in new namespaces added by extensions, please list your extension's custom namespaces here. If you define a constant for a custom namespace, list it here too.

Note that these are only default namespaces. All extensions defining new namespaces should provide the installer with a method of configuring the extension to use a different range of namespaces for its custom namespaces.

Naturally some namespaces listed on this page will overlap, and violate the recommendations listed here. The recommendations are good practices new extensions should try to adhere to to avoid conflicts; for legacy reasons, old extensions that have already created conflicts and bad practice can't simply be changed but are listed here to help avoid even more conflicts.

Note Note: Namespaces using numbers from 3000 and higher are meant to be used by system administrators to define their custom namespaces. Thus extension developers should not use this range.

Negative IDs[edit]

Warning Warning: Do not use negative IDs for extensions. Ever.
MediaWiki Core
ID Name Constant Remark
Note Note:2 namespaces have negative indexes and have special purposes. You cannot create or delete pages in these namespaces, and there are no corresponding discussion namespaces.
-2 Media: NS_MEDIA Alias for direct links to media files
-1 Special: NS_SPECIAL Holds special pages

ID 0-99[edit]

MediaWiki Core[edit]

MediaWiki Core
ID Name Constant Remark
0 : NS_MAIN
1 Talk: NS_TALK
2 User: NS_USER
3 User_talk: NS_USER_TALK
4 Project: NS_PROJECT
5 Project_talk: NS_PROJECT_TALK
6 File: NS_FILE
7 File_talk: NS_FILE_TALK
8 MediaWiki: NS_MEDIAWIKI
9 MediaWiki_talk: NS_MEDIAWIKI_TALK
10 Template: NS_TEMPLATE
11 Template_talk: NS_TEMPLATE_TALK
12 Help: NS_HELP
13 Help_talk: NS_HELP_TALK
14 Category: NS_CATEGORY
15 Category_talk: NS_CATEGORY_TALK
Note Note:If core is to define any new default namespace it will likely continue on from here with 16-17, please take care to avoid this area.

WikiLexicalData[edit]

WikiLexicalData
ID Name Constant Remark
16 Expression: NS_EXPRESSION
17 Expression_talk:
24 DefinedMeaning: NS_DEFINEDMEANING
25 DefinedMeaning_talk:

LiquidThreads[edit]

LiquidThreads
ID Name Constant Remark
90 Thread: NS_LQT_THREAD
91 Thread_talk: NS_LQT_THREAD_TALK
92 Summary: NS_LQT_SUMMARY
93 Summary_talk: NS_LQT_SUMMARY_TALK

ID 100-199[edit]

Warning Warning: The namespaces in 100-199 are reserved for site-specific namespaces, and should not be used by extensions. Many extensions are already using this range, though, so be careful. If you're writing a new extension you should never hardcode any namespaces inside the 100-199 range.

Wikimedia Foundation[edit]

Many Wikimedia Foundation wikis have site-specific namespaces in this range. Including the Portal namespace (100) on most Wikipedia projects, Creator namespace (100) on Wikimedia Commons, the Extension namespace (102) on mediawiki.org, the Subject namespace (112) on English Wikibooks, and many others.

Semantic MediaWiki[edit]

Semantic MediaWiki
ID Name Constant Remark
102 Property: SMW_NS_PROPERTY
103 Property_talk: SMW_NS_PROPERTY_TALK
104 Type: SMW_NS_TYPE No longer used, as of version 1.6.0 (still supported).
105 Type_talk: SMW_NS_TYPE_TALK No longer used, as of version 1.6.0 (still supported).
108 Concept: SMW_NS_CONCEPT
109 Concept_talk: SMW_NS_CONCEPT_TALK
112 Rule: SMW_NS_RULE
113 Rule_talk: SMW_NS_RULE_TALK

Page Forms[edit]

Page Forms
ID Name Constant Remark
106 Form: PF_NS_FORM
107 Form_talk: PF_NS_FORM_TALK

DPLforum[edit]

DPLforum
ID Name Constant Remark
110 Forum: NS_FORUM
111 Forum_talk: NS_FORUM_TALK

Wikibase[edit]

Wikibase Repository
ID Name Constant Remark
120 Item: WB_NS_ITEM many installations, including Wikidata, use the main namespace instead
121 Item_talk: WB_NS_ITEM_TALK many installations, including Wikidata, use the main talk namespace instead
122 Property: WB_NS_PROPERTY
123 Property_talk: WB_NS_PROPERTY_TALK
WikibaseLexeme
ID Name Constant Remark
146 Lexeme:
147 Lexeme_talk:

Semantic Access Control[edit]

Semantic Access Control
ID Name Constant Remark
160 UserGroup: ACL_NS_USERGROUP
162 ACL: ACL_NS_ACL

Semantic Drilldown[edit]

Semantic Drilldown
ID Name Constant Remark
170 Filter: SD_NS_FILTER No longer used, as of version 2.0 (still supported).
171 Filter_talk: SD_NS_FILTER_TALK No longer used, as of version 2.0 (still supported).

ID 200-299[edit]

Wikimedia Foundation[edit]

SocialProfile[edit]

SocialProfile
ID Name Constant Remark
200 UserWiki: NS_USER_WIKI
201 UserWiki_talk: NS_USER_WIKI_TALK Since r93317.
202 User_profile: NS_USER_PROFILE
203 User_profile_talk: NS_USER_PROFILE_TALK Since r93317.

examples[edit]

examples
ID Name Constant Remark
234 XML: NS_XML
235 XML_talk: NS_XML_TALK

Semantic Text Annotator and Semantic Image Annotator[edit]

Semantic Text Annotator,Semantic Image Annotator
ID Name Constant Remark
248 Annotation: NS_ANNOTATION
249 Annotation_talk: NS_ANNOTATION_TALK

Proofread Page[edit]

Proofread Page
ID Name Constant Remark
250 Page: $wgProofreadPageNamespaceIds['page']
251 Page_talk: ID is $wgProofreadPageNamespaceIds['page'] + 1
252 Index: $wgProofreadPageNamespaceIds['index']
253 Index_talk: ID is $wgProofreadPageNamespaceIds['index'] + 1

TrustedMath[edit]

TrustedMath
ID Name Constant Remark
262 Math: NS_TRUSTEDMATH
263 Math_talk: NS_TRUSTEDMATH_TALK

Widgets[edit]

Widgets
ID Name Constant Remark
274 Widget: NS_WIDGET
275 Widget_talk: NS_WIDGET_TALK

EmbedScript[edit]

Extension:EmbedScript
ID Name Constant Remark
280 JSApplet: NS_JSAPPLET
281 JSApplet_talk: NS_JSAPPLET_TALK

ID 300-399[edit]

PollNY[edit]

PollNY
ID Name Constant Remark
300 Poll: NS_POLL
301 Poll_talk: NS_POLL_TALK

MOOC[edit]

MOOC
ID Name Constant Remark
350 Mooc: NS_MOOC
351 Mooc_talk: NS_MOOC_TALK

Wikia[edit]

300 - 399. Wikia has been seen using namespaces in this range for its custom extensions and configurations. To avoid conflicts in case Wikia extensions are ported to work outside of Wikia it would be best to avoid defining new extensions that use this range. Wikia alters the namespaces for some extensions used on its own wikis. Please also take these into account while coming up with new namespace numbers to use in new extensions.

ID 400-499[edit]

Video[edit]

Video
ID Name Constant Remark
400 Video: NS_VIDEO
401 Video_talk: NS_VIDEO_TALK

Maps[edit]

Maps
ID Name Constant Remark
420 GeoJson: NS_GEO_JSON
421 GeoJson_talk: NS_GEO_JSON_TALK

QuizTabulate[edit]

QuizTabulate
ID Name Constant Remark
430 Quiz: QuizTabulate_NS_QUIZ
431 Quiz_talk: QuizTabulate_NS_QUIZ_TALK

Education Program[edit]

Education Program
ID Name Constant Remark
446 Education_Program: EP_NS
447 Education_Program_talk: EP_NS_TALK

BoilerRoom[edit]

BoilerRoom
ID Name Constant Remark
450 Boilerplate: NS_BOILERPLATE
451 Boilerplate_talk: NS_BOILERPLATE_TALK

UploadWizard[edit]

UploadWizard
ID Name Constant Remark
460 Campaign: NS_CAMPAIGN JSON describing metadata for an Upload Campaign
461 Campaign_talk: NS_CAMPAIGN_TALK

EventLogging[edit]

EventLogging
ID Name Constant Remark
470 Schema: NS_SCHEMA JSON schemas describing data models
Note Note: Constant name also used by: LinkedWiki
471 Schema_talk: NS_SCHEMA_TALK Note Note: Constant name also used by: LinkedWiki

ZeroBanner[edit]

ZeroBanner
ID Name Constant Remark
480 Zero: NS_ZERO JSON configuration (outdated) describing Zero site behavior for this carrier
These namespaces are also defined in a test file for Extension:JsonConfig.
481 Zero_talk: NS_ZERO_TALK

JsonConfig[edit]

JsonConfig
ID Name Constant Remark
482 Config: NS_CONFIG JSON Configuration blob used by multiple systems
483 Config_talk: NS_CONFIG_TALK
486 Data: NS_DATA Additional JSON data. As of 2015-02 you can store arbitrary valid JSON in the subnamespace Data:Json, e.g. Data:Json:MyDataset. This is a developing convention on Wikimedia projects that use JsonConfig and Graph.
Note Note: Constant name also used by: LinkedWiki
487 Data_talk: NS_DATA_TALK

Graph[edit]

Graph
ID Name Constant Remark
484 Graph: Graph data. This is a convention on Wikimedia projects that use the extension, the extension doesn't define a particular namespace.
485 Graph_talk:

NotebookViewer[edit]

NotebookViewer
ID Name Constant Remark
486 Notebook: NS_NOTEBOOK Jupyter Notebook data

GWToolset[edit]

GWToolset
ID Name Constant Remark
490 GWToolset: NS_GWTOOLSET
491 GWToolset_talk: NS_GWTOOLSET_TALK

FileAnnotations[edit]

FileAnnotations
ID Name Constant Remark
492 File_annotations: NS_FILE_ANNOTATIONS
493 File_annotations_talk: NS_FILE_ANNOTATIONS_TALK

OpenStackManager[edit]

OpenStackManager
ID Name Constant Remark
498 Nova_Resource: NS_NOVA_RESOURCE
499 Nova_Resource_Talk: NS_NOVA_RESOURCE_TALK

ID 500-599[edit]

Some sites try to make use of the 500-599 range for site namespaces.[citation needed] To avoid conflicting with those sites it would be a good idea to avoid this range while creating new extensions.

BlogPage[edit]

BlogPage
ID Name Constant Remark
500 Blog: NS_BLOG Extension:MiniInvite adds a minor bit of functionality when this namespace constant is defined (see /includes/MiniInvite.hooks.php).
501 Blog_talk: NS_BLOG_TALK

ID 600-699[edit]

FanBoxes[edit]

FanBoxes
ID Name Constant Remark
600 UserBox: NS_FANTAG
601 UserBox_talk: NS_FANTAG_TALK

MintyDocs[edit]

MintyDocs
ID Name Constant Remark
620 Draft: MD_NS_DRAFT The PageTriage extension also makes use of a "Draft" namespace, although it does not define one; the administrator must define one themselves.
621 Draft_talk: MD_NS_DRAFT_TALK

OpenStackManager[edit]

OpenStackManager
ID Name Constant Remark
666 Heira: NS_HEIRA
667 Heira_Talk: NS_HEIRA_TALK

ID 700-799[edit]

LinkFilter[edit]

LinkFilter
ID Name Constant Remark
700 Link: NS_LINK
701 Link_talk: NS_LINK_TALK

TimedMediaHandler[edit]

TimedMediaHandler
ID Name Constant Remark
710 TimedText: NS_TIMEDTEXT ID can be changed with $wgTimedTextNS.
711 TimedText_talk: NS_TIMEDTEXT_TALK ID can be changed with $wgTimedTextNS.
Note Note:TimedMediaHandler reserves namespaces for timed text tracks.

GitAccess (WIP)[edit]

GitAccess
ID Name Constant Remark
730 GitAccess_root: NS_GITACCESS_ROOT
731 GitAccess_root_talk: NS_GITACCESS_ROOT_TALK

ID 800-899[edit]

QPoll[edit]

QPoll
ID Name Constant Remark
800 Interpretation: NS_QP_INTERPRETATION
801 Interpretation_talk: NS_QP_INTERPRETATION_TALK
Note Note:QPoll reserves namespaces for interpretation scripts.

SemanticMustacheFormat[edit]

SemanticMustacheFormat
ID Name Constant Remark
806 Mustache: SRFM_NS_MUSTACHE
807 Mustache_talk: SRFM_NS_MUSTACHE_TALK

JADE[edit]

JADE
ID Name Constant Remark
810 Jade: NS_JADE
811 Jade_talk: NS_JADE_TALK


R[edit]

R
ID Name Constant Remark
814 R: NS_EXTR Used for help pages and (interactive) examples.
815 R_talk: NS_EXTR_TALK


Scribunto[edit]

Scribunto
ID Name Constant Remark
828 Module: NS_MODULE
829 Module_talk: NS_MODULE_TALK

SecurePoll[edit]

SecurePoll
ID Name Constant Remark
830 SecurePoll: NS_SECUREPOLL Set $wgSecurePollUseNamespace true to enable.
831 SecurePoll_talk: NS_SECUREPOLL_TALK Set $wgSecurePollUseNamespace true to enable.

CommentStreams[edit]

CommentStreams
ID Name Constant Remark
844 CommentStreams: NS_COMMENTSTREAMS may be overridden by $wgCommentStreamsNamespaceIndex
845 CommentStreams_talk: NS_COMMENTSTREAMS_TALK Presently unused.

CentralNotice[edit]

CentralNotice
ID Name Constant Remark
866 CNBanner: NS_CN_BANNER Staging area for pending banner translations.
867 CNBanner_talk: NS_CN_BANNER_TALK Presently unused.

ID 1000+[edit]

The 1000+ range starts to get fairly high and is a range some sites may attempt to use to avoid conflicts with extensions. So be wary of defining new namespaces within this range, especially near 1000.

Piwo[edit]

Piwo
ID Name Constant Remark
1024 Gram: NS_GRAM
1025 Gram_talk: NS_GRAM_TALK

Translate[edit]

Translate
ID Name Constant Remark
1198 Translations: NS_TRANSLATIONS
1199 Translations_talk: NS_TRANSLATIONS_TALK
Note Note:Translate extension uses these namespaces by default, but they can be overridden. FYI translatewiki.net uses namespaces from 1200 onward to hold product translations.

BlueSpice[edit]

BlueSpice
ID Name Constant Remark
1502 Blog: NS_BLOG Note Note: Constant name also used by: BlogPage
1503 Blog_talk: NS_BLOG_TALK Note Note: Constant name also used by: BlogPage
1504 Book: NS_BOOK
1505 Book_talk: NS_BOOK_TALK
Note Note:The BlueSpiceExtensions bundle contains only two extensions with a namespace at the moment. This may change in the near future. Therefore the Hallo Welt! team would appreciate it if the range of 1500-1599 could be reserved for this package.

ID 2000+[edit]

Gadgets[edit]

Gadgets
ID Name Constant Remark
2300 Gadget: NS_GADGET
2301 Gadget_talk: NS_GADGET_TALK
2302 Gadget_definition: NS_GADGET_DEFINITION
2303 Gadget_definition_talk: NS_GADGET_DEFINITION_TALK

Flow[edit]

Flow
ID Name Constant Remark
2600 Topic: NS_TOPIC allows users to watch individual Flow topic discussions
Defined as a stub for testing in MassMessage's /tests/phan/stubs/Flow.php

Semantic_Genealogy[edit]

Semantic_Genealogy
ID Name Constant Remark
2700 Genealogy: NS_SGENEALOGY
2701 Genealogy_talk: NS_SGENEALOGY_TALK
2702 Genealogy_template: NS_SGENEALOGY_TEMPLATE
2703 Genealogy_template_talk: NS_SGENEALOGY_TEMPLATE_TALK
2704 Genealogy_form: NS_SGENEALOGY_FORM
2705 Genealogy_form_talk: NS_SGENEALOGY_FORM_TALK

CourseEditor[edit]

CourseEditor
ID Name Constant Remark
2800 Course: NS_COURSE
2801 Course_talk: NS_COURSE_TALK

ID 3000+[edit]

So far, no known extensions have defined default namespaces in the 3000+ range. For now, it would be best to avoid using this range for extensions, so that sites can use this range to define their custom namespaces without fear of conflict.

In accordance with this, the BlueSpice Namespace Manager uses the range above 3000 to create custom namespaces.

ID 5000+[edit]

Newsletter[edit]

Newsletter
ID Name Constant Remark
5500 Newsletter: NS_NEWSLETTER
5501 Newsletter_talk: NS_NEWSLETTER_TALK

MediaWiki Core[edit]

MediaWiki Core
ID Name Constant Remark
5600 : NS_UNITTEST Defined in /test/phpunit/includes/user/UserTest.php
5601 : NS_UNITTEST_TALK Defined in /test/phpunit/includes/user/UserTest.php

ID 10000+[edit]

LinkedWiki[edit]

LinkedWiki
ID Name Constant Remark
10000 Data: NS_DATA Note Note: Constant name also used by: JsonConfig
10002 UserData: NS_USER_DATA
10010 Schema: NS_SCHEMA Note Note: Constant name also used by: EventLogging
10011 Schema_talk: NS_SCHEMA_TALK Note Note: Constant name also used by: EventLogging
10030 Datatype: NS_DATATYPE
10031 Datatype_talk: NS_DATATYPE_TALK

See also[edit]