we are currently using Sitecore 9.0.2 with SXA 1.8.1

Is there a way to limit the Auto-complete on the Location finder to a particular country or city?

  • No, there is no such possibility. Commented Jun 5, 2019 at 15:11

1 Answer 1


For a project I worked on we created a custom Maps Connector theme. We copied the script provided OOTB with SXA, renamed it, then made some changes to it.

Here is an example of how we changed it so the country was included:

    input: queryParams.text,
    'componentRestrictions': {
        'country': 'us'
    'types': ['geocode']
}, function(results) {
    var predictions = [],
    if (results != null && results.length) {
        length = results.length >= maxResults ? maxResults : results.length;

        for (var i = 0; i < length; i++) {
            predictions.push(_.extend(results[i], {
                text: results[i].description

        console.log("Adding predictions to storage.");
        sessionStorage.setItem(key, JSON.stringify(predictions));
    } else {

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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