The figures below show illustrate the principle underlying the Pythagorean Theorem. Given any right triangle (in grey in these figures), it's possible to construct identically shaped and sized (“congruent”) triangles and also squares from the base and height ... and to show that the shape enclosing all of these is a square. (Those are shown, on the left of these figures, in pink, grey, and light steel blue).
From one edge of that enclosing square, we can construct another congruent square (shown to the right in each of the figures below). Inscribed within that second square we can construct a ring of additional clones of our given triangle. The shape within that ring, formed by their hypotenuses, is a also square. (That's shaded in medium turquoise in the figures below).
These figures are visual equations.
The area of (enclosing) squares are equal. The areas of all the triange clones are equal to one another. If we subtract the areas of the four triangles (arranged in rectangles in the left of each figure, and the four in a "ring" to the right) ... then the remaining space in the left square (the two pink squares) will be of equal area to the remaining space on the right (shaded in lavender).
In other words the sum of the two pink squares (“a” & “b”) are equal to the lavender square (“c”). This is the familiar equation::
a2 + b2 = c2
The animation on the lower figure show how these relationships work for the full range of heights and widths. Only the ratio of height and width matter. None of this is based on any sort of units; it's a matter of proportions. The animation is limited to a subset of the possible ratios because the graphics just look bad for excessively oblique triangles.
It's worth nothing that this image and the animation is not a proof.
It is possible to prove the Pythagorean Theorem by constructing an image similar to this one from any given right triangle using only compass and straightedge techniques. Doing so is an exercise left to the reader.
You can learn more about these techniques by playing the game at: Euclidea.xyz.