TomTom Maps for JavaScript
    Preparing search index...

    Function reverseGeocode

    • Convert geographic coordinates into human-readable addresses (reverse geocoding).

      Reverse geocoding translates latitude/longitude coordinates into street addresses, which is essential for location-based applications that need to display addresses from GPS coordinates or map clicks.

      Parameters

      • params: ReverseGeocodingParams

        Reverse geocoding parameters including coordinates

      • OptionalcustomTemplate: Partial<ReverseGeocodingTemplate>

        Advanced customization for request/response handling

      Returns Promise<ReverseGeocodingResponse>

      Promise resolving to the address for the given coordinates

      Common use cases:

      • Tracking applications: Convert GPS coordinates from devices into addresses
      • Map interactions: Display address when user clicks on map
      • Location sharing: Show readable location instead of coordinates
      • Delivery apps: Confirm pickup/dropoff addresses from driver location
      • Asset tracking: Display current location of vehicles or equipment

      Features:

      • Returns complete address hierarchy (street, city, state, country)
      • Returns the result type (address, street, or geography)
      • Narrows results to administrative areas with geographyType
      • Direction-aware street matching with heading
      // Get address for coordinates
      const address = await reverseGeocode({
      key: 'your-api-key',
      position: [4.9041, 52.3676] // Amsterdam coordinates
      });
      // Returns: Dam, 1012 Amsterdam, Netherlands

      // Get the address matched along a given travel direction
      const specificAddress = await reverseGeocode({
      key: 'your-api-key',
      position: [-77.0369, 38.8977], // Washington DC
      heading: 90 // Traveling east
      });

      // Get the containing municipality instead of the street
      const municipality = await reverseGeocode({
      key: 'your-api-key',
      position: [-74.0060, 40.7128], // New York
      geographyType: ['Municipality']
      });