Custom Google Maps Marker Icons

So here’s what I’m trying to do in the most basic sense. I’ll leave out the fluff around this to simplify the problem.

I have a Google Marker on my maps that looks like this:

This is the default marker.

I need to change the marker icon to a custom one. For purposes of this example, I am using this one:

I tried adding this bit of JSON code to the Maps custom JSON field but it causes the maps element to not even load so it can’t be right:

 [
{      
"elementType": "marker",
"stylers": [
        {
            "icon": 'https://developers.google.com/maps/documentation/javascript/examples/full/images/beachflag.png',
        }
    ]
},
]

My question is: What is the proper JSON code to change the marker icon? OR If there is a different way to do this I would love to hear it.

Thank you in advance for your help

1 Like

I am also interested in hearing if this is possible. From my research, I didn’t believe it was possible just with JSON changes.

Would be easy if we could add custom javascript because I can store it as a variable but I am very unfamiliar with JSON and seems like it cannot handle that kind of scripting.

Hi @iron49man unfortunately this is not currently possible to change with the JSON method. If it is a feature you require then pelase consider making a request here https://ideas.adalo.com/feature-requests

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.