Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

mrnaveed's avatar

Google maps api for satellite view

Is there any functionality in google maps api to show satellite view of an address e.g; address of a shop and then give area of roof? As this website is doing??? https://roofr.com

0 likes
3 replies
D9705996's avatar

You can use the geocoding api from Google.

https://developers.google.com/maps/documentation/geocoding/intro#GeocodingResponses

The geometry section should help you

"geometry" : {
            "location" : {
               "lat" : 37.4224764,
               "lng" : -122.0842499
            },
            "location_type" : "ROOFTOP",
            "viewport" : {
               "northeast" : {
                  "lat" : 37.4238253802915,
                  "lng" : -122.0829009197085
               },
               "southwest" : {
                  "lat" : 37.4211274197085,
                  "lng" : -122.0855988802915
               }
            }
         },

You can calcute the area from the difference between the northeast and southwest long/lat in viewport

Please or to participate in this conversation.