• Home
  • Random
  • Nearby
  • Log in
  • Settings
Donate Now If Wikipedia is useful to you, please give today.
  • About Wikipedia
  • Disclaimers
Wikipedia

Template:Chart

  • Template
  • Talk
  • Language
  • Watch
  • View source
Template documentation[view] [edit] [history] [purge]

Contents

  • 1 Copy templates
  • 2 Examples
    • 2.1 full width
    • 2.2 other data source and border
    • 2.3 thumbnail, caption, and source
    • 2.4 aligned and fixed width
    • 2.5 aligned and fixed width thumbnail
    • 2.6 centered, fixed width, border, caption and source
  • 3 TemplateData
  • 4 See also

Copy templates

Standard

{{Chart|chart=.chart}}

Full

{{Chart
| chart      = 
| data       = 
| thumb      =
| align      = 
| width      = 
| border     = 
| style      = 
| caption    =
| source     = 
}}

or

{{Chart|thumb|align|width|caption|chart=.chart|data=.tab|border=|style=|source=.tab}}

Examples

full width

{{Chart
| chart = Autobahn network length.Line.chart
}}
Länge in KilometernJahr03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Entwicklung der Netzlänge von Reichs- und B...
See or edit chart definition.

other data source and border

{{Chart
| chart      = Monthly stream discharges.chart
| data       = GRDC-1530100 monthly discharge.tab
| border     = 1
}}
Discharge in m³/sMonth0100200300400500JanMarMayJulSepNovMinMeanMaxHydrograph: Monthly discharge
See or edit source data.

thumbnail, caption, and source

{{Chart
| thumb
| caption = Autobahn network length.
| source  = Autobahn network length.tab
| chart   = Autobahn network length.Line.chart
}}
Länge in KilometernJahr03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Entwicklung der Netzlänge von Reichs- und B...
Autobahn network length. See or edit source data.

aligned and fixed width

{{Chart
| chart      = Autobahn network length.Line.chart
| align      = right
| width      = 400px
}}
Länge in KilometernJahr03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Entwicklung der Netzlänge von Reichs- und B...
See or edit chart definition.

aligned and fixed width thumbnail

{{Chart
| thumb
| chart      = Autobahn network length.Line.chart
| align      = left
| width      = 400px
}}
Länge in KilometernJahr03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Entwicklung der Netzlänge von Reichs- und B...
See or edit chart definition.

centered, fixed width, border, caption and source

{{Chart
| chart      = Autobahn network length.Line.chart
| align      = center
| width      = 400px
| caption    = Autobahn network length.
| source     = Autobahn network length.tab
}}
Länge in KilometernJahr03K6K9K12K15K1932195019851999200620132020ReichsautobahnBundesautobahn (West Germany)Bundesautobahn (Germany)Entwicklung der Netzlänge von Reichs- und B...
Autobahn network length. See or edit source data.

TemplateData

This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. See a monthly parameter usage report for Template:Chart in articles based on its TemplateData.

TemplateData for Chart

Includes a chart ([[Help:Charts]]) with source attribution and allows adjusting alignment, width, and border.

Template parameters[Edit template data]

ParameterDescriptionTypeStatus
Display as thumbnailthumb 1

Set to any value to display in a gray box like an image thumbnail

Suggested values
thumb
Example
thumb
Lineoptional
Alignmentalign 2

Chart alignment, either "left", "right", or "center"

Suggested values
left right center
Lineoptional
Widthwidth 3

Width in pixels or percent

Suggested values
400px 600px 50% 100%
Lineoptional
Captioncaption 4

Caption to display before the source information. Make sure to use ending punctuation.

Example
This is a chart caption.
Stringoptional
Chart definitionchart definition

Chart on Wikimedia Commons, without the "Data:" prefix

Example
Example.chart
Linerequired
Chart datadata

.tab on Wikimedia Commons, without the "Data:" prefix (overrides the specification in the chart definition)

Example
Example.tab
Linesuggested
Source attributionsource

Source .tab file to be linked at the bottom, without the "Data:" prefix. If not specified, it will fallback to displaying the value of "data" or "chart".

Example
Example.tab
Linesuggested
Borderborder

Set to "1" to enable a border

Suggested values
1
Example
1
Booleanoptional
CSS stylesstyle

Additional CSS styles (beyond width and border)

Example
border-width:5px;
Lineoptional
Hide sourcehideSource

Set to any value to disable linking to the source

Suggested values
1
Example
1
Booleanoptional

See also

  • Help:Charts
  • {{Image frame}}
The above documentation is transcluded from Template:Chart/doc. (edit | history)
Editors can experiment in this template's sandbox (edit | diff) and testcases (edit) pages.
Add categories to the /doc subpage. Subpages of this template.
Retrieved from "https://en.wikipedia.org/w/index.php?title=Template:Chart&oldid=1307614903"
Last edited on 24 August 2025, at 18:00

Languages

    • Deutsch
    • Français
    • Македонски
    • Română
    Wikipedia
    • Wikimedia Foundation
    • Powered by MediaWiki
    • This page was last edited on 24 August 2025, at 18:00 (UTC).
    • Content is available under CC BY-SA 4.0 unless otherwise noted.
    • Privacy policy
    • About Wikipedia
    • Disclaimers
    • Contact Wikipedia
    • Code of Conduct
    • Developers
    • Statistics
    • Cookie statement
    • Terms of Use
    • Desktop