I am very new to GIS so please forgive me if the question is naive, but I haven't found a solution yet.

I generated a mock hexbin in QGIS using MMQGIS plugin, with project set to EPSG:4326 and saved to PostGIS.

Expected result

When queried as Geojson via Postgis, the returned data looks stretched in Google Maps. End result

I have tried to save in EPSG:3857 Google Mercator but that doesn't work either.

Creating the map in 3857 was the answer, however I did try before without success, however trying via DB Manager did the trick, the Target SRID was the missing piece in the puzzle!

enter image description here


When projecting data from a long/lat system to a Mercator projection, your data will always be stretched by a factor of sec(y) (i.e. f1) in the vertical direction (derivative of Mercator equations that you can find e.g. here).

At your latitude (London), the stretching factor will be around 1.6.

Some solutions you could try:

  • create your hexagonal grid directly in a Mercator-type projection (EPSG:3857 should be fine)
  • stretch your grid by 1/1.6 in the vertical direction (or 1.6 in the horizontal direction) with PostGIS or some other tool (no clue about the way to proceed, though)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.