Number rounding

Round a decimal number with an explicit precision and rule.

Both dots and commas are accepted as decimal separators. Nearest ties round away from zero: 1.005 → 1.01 and −1.005 → −1.01 at two places. Toward −∞: −1.21 → −1.3 at one place; toward zero: −1.21 → −1.2. Trailing zeros show the selected precision.

Both dots and commas are accepted as decimal separators.

Your inputs stay in your browser.

Method and assumptions

Method version 1.0.0 · Updated

Round to a precision

Formula: Decimal rounding to p places according to the selected rule

Both dots and commas are accepted as decimal separators. Nearest ties round away from zero: 1.005 → 1.01 and −1.005 → −1.01 at two places. Toward −∞: −1.21 → −1.3 at one place; toward zero: −1.21 → −1.2. Trailing zeros show the selected precision.

value
Number to round
places
Decimal places
mode
Rounding rule

Exact decimal input of at most 80 characters, including sign and separator; 0 to 12 decimal places in the result. Trailing zeros are preserved. No second display rounding.