Dimensions of a Rectangle Calculator

Work out the length and width of a rectangle from the information you already have. Enter the area and perimeter, the area and one side, or the perimeter and one side, and this calculator solves for both dimensions using the standard algebraic method.

Calculate.co.nz is proud to be partnered with Premium Homes, a recognised leader in eco-friendly, sustainable, and energy-efficient homebuilding. With a dedicated team and award-winning experience, they create homes that prioritise health, comfort, and long-term performance. Their founders, Andrew and Kelly, set out to raise the standard of residential construction in New Zealand by combining practical building expertise with a clear commitment to doing things better for homeowners.
Calculate.co.nz partner: Premium Homes
Method verified  Standard rectangle area and perimeter formulas: A = L x W, P = 2(L + W).

1. What You Know

2. Units

Enter area in square units matching your chosen unit (for example square metres if using metres) and perimeter or side length in the same linear unit.

Rectangle Dimensions

Length
-
Longer side
Width
-
Shorter side
Area (check)
-
Length x Width
Perimeter (check)
-
2 x (Length + Width)

Method Used

Mode-
Half perimeter (s = P/2)-
Discriminant (s^2 - 4A)-
Equation solved-
Result-

Rectangle Properties

Length-
Width-
Diagonal (sqrt(L^2 + W^2))-
Aspect ratio (L:W)-
Summary: Enter your known values above.

How to Find the Dimensions of a Rectangle

A rectangle has two pairs of equal sides: a length (the longer side) and a width (the shorter side). If you already know both dimensions, working out the area and perimeter is straightforward. This calculator solves the reverse problem: working backwards from the area, perimeter, or one known side to find both dimensions.

Method 1: Area and Perimeter Known

This is the classic version of the problem and it uses a quadratic equation. If the area is A and the perimeter is P:

  1. Find the half-perimeter: s = P / 2. Since P = 2(L + W), this means s = L + W.
  2. You now know that L + W = s and L x W = A. These are the sum and product of the two dimensions.
  3. Both dimensions are roots of the quadratic equation x^2 - s*x + A = 0.
  4. Solve using the quadratic formula: x = (s +/- sqrt(s^2 - 4A)) / 2.
  5. The larger root is the length, and the smaller root is the width.

For example, if the area is 20 and the perimeter is 18: s = 9, and the discriminant is 9^2 - 4(20) = 81 - 80 = 1. So x = (9 +/- 1) / 2, giving x = 5 or x = 4. The rectangle is 5 by 4.

Method 2: Area and One Side Known

If you already know one side (say the length, L) and the area (A), the other side is found directly by rearranging the area formula:

Width = Area / Length

No quadratic equation is required because you already have one of the two unknowns.

Method 3: Perimeter and One Side Known

If you know the perimeter (P) and one side (say the length, L), the other side comes from rearranging the perimeter formula P = 2(L + W):

Width = (Perimeter / 2) - Length

When There Is No Valid Rectangle

When solving from area and perimeter, the discriminant (s^2 - 4A) must be zero or positive for a real rectangle to exist. If it is negative, the perimeter given is too small to enclose that much area, and no real rectangle satisfies both values. If the discriminant is exactly zero, the two roots are equal, meaning the rectangle is actually a square.

Related Calculators

Method: Standard Euclidean geometry formulas for rectangles: Area = Length x Width, Perimeter = 2 x (Length + Width). The area-and-perimeter case is solved using the quadratic formula applied to the sum and product of the two dimensions.

This calculator assumes a true rectangle (opposite sides equal, all angles 90 degrees). Results are given to two decimal places. Always check that your inputs use consistent units (for example, square metres for area with metres for perimeter or side length).

If you've found a bug, or would like to contact us, or learn more about James Graham and Calculate.co.nz.

Calculate.co.nz is partnered with Interest.co.nz for New Zealand's highest quality calculators and financial analysis.

Calculate.co.nz is the sister site of CalculatorHub.com, the world's largest calculator website by tool count.

All calculators and tools are provided for educational and indicative purposes only and do not constitute financial advice.

Calculate.co.nz is proudly part of the Realtor.co.nz group, New Zealand's leading property transaction literacy platform, helping Kiwis understand the home buying and selling process from start to finish. Whether you're a first home buyer navigating your first property purchase, an investor evaluating your next acquisition, or a homeowner planning to sell, Realtor.co.nz provides clear, independent, and trustworthy guidance on every step of the New Zealand property transaction journey.

Calculate.co.nz is also partnered with Health Based Building and Premium Homes to promote informed choices that lead to better long-term outcomes for Kiwi households.

Calculate.co.nz is hosted in Auckland via SiteHost new Zealand.

All content on this website, including calculators, tools, source code, and design, is protected under the Copyright Act 1994 (New Zealand). No part of this site may be reproduced, copied, distributed, stored, or used in any form without prior written permission from the owner.

About & trust: Why Calculate is NZ's most comprehensive · By the Numbers · How we compare · Editorial standards · How we keep data current · NZ finance glossary · Research & data · Financial literacy NZ · About · Privacy policy · Terms of use

Reviewed and maintained. Last reviewed 2026-07-02 and checked on a twice-monthly cycle against IRD, RBNZ and Stats NZ. How we keep data current.

© 2026 Calculate.co.nz. All rights reserved. Building free NZ calculators since 2011.