How To Measure: Garden Gates
Take 3 measurements between the posts. Across the top, middle and bottom. Make note of the smallest measurement.
The reductions you need to make depend on the style of garden gate you have and how you are going to mount the hinges; on the back of the posts or in-between them.

Rear of the Post's...
If you are mounting the hinges on the rear of the post with the back edge of the gate inline with the back of the post, reduce 20mm from your lowest measurement. The gate will open inwards towards the property.