Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

This is the documentation page for Module:Number

Formats numbers with thousand separators. Non-numeric input is returned unchanged, so the module is safe to use on mixed content (e.g., empty text, labels passed through in error).

Examples

Code Result
{{#invoke:Number|main|value=1500}} 1,500
{{#invoke:Number|main|value=1500.50}} 1,500.50
{{#invoke:Number|main|value=-1500}} -1,500
{{#invoke:Number|main|value=abc}} abc

The value parameter is required (named). Leading and trailing whitespace is trimmed.

Notes

  • Trailing zeros in the decimal portion are preserved: 1500.50 formats as 1,500.50, not 1,500.5.
  • Input like 1500. (trailing dot, no digits) is treated as invalid and returned unchanged.