(written from a Production point of view)
\'ka-nen\ (n.) – a sanctioned or accepted group or body of related works
As Star Trek grew in both size and popularity in the 1980s, fans considered how to treat the ever-growing collection of episodes, movies, novels, comics, technical manuals, and more.
The Star Trek canon is generally defined as all live-action television series and feature films released by Paramount Pictures. With the release of Star Trek: The Animated Series on DVD, the studio appears to have changed its stance, and is now listing the cartoon series (aired 1973–1974), as a part of established canon. (wbm wbm wbm) The various "official" references (such as the Star Trek Encyclopedia or the Star Trek Chronology) may be used as a guide to canon information, but are not canon in and of themselves.
The definition of Star Trek canon may vary for different fans, and therefore for a reference source like Memory Alpha, the question may become especially difficult.
In those cases, the term fanon is used to refer to "fan canon" (of which the term is a portmanteau). It applies to certain "facts" that may have been accepted as a truth by a large number of fans, and thus either replaces an established canonical fact in the minds of those fans, or fills a plot-hole.
A large body of licensed Star Trek works exists that, while approved for publication by Paramount, are not considered part of Star Trek canon. This includes novels, comics, games, and older reference books such as the Star Fleet Technical Manual.
Note that over the years background information from non-canon works has worked its way into canon Star Trek. These include the first names of Hikaru Sulu and Nyota Uhura for example. Remastered Star Trek also added further examples, such as the design of the non-canon 23rd century Starbase 47 being used for Starbase 6.
There is also a large body of non-canon unlicensed work produced by fans themselves. Until recently this fan fiction, while enjoyed by many, was dismissed by almost all in relation to canon.
The recent growth of episodes and films produced by former Star Trek cast and crew has garnered much greater attention than traditional fan fiction. Some of this material is considered to be more official than the novels and games by some fans due to the inclusion of actors from the various Star Trek series. The two projects that fall into this group are: