Bulk GPS Coordinate Format Converter avatar

Bulk GPS Coordinate Format Converter

Pricing

from $1.44 / 1,000 coordinate row processeds

Go to Apify Store
Bulk GPS Coordinate Format Converter

Bulk GPS Coordinate Format Converter

Convert mixed GPS coordinate strings to decimal degrees, DMS, and DDM with validation, precision, and per-row errors for GIS data cleanup.

Pricing

from $1.44 / 1,000 coordinate row processeds

Rating

0.0

(0)

Developer

Stas Persiianenko

Stas Persiianenko

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

2 days ago

Last modified

Categories

Share

Normalize mixed coordinate lists without sending location data to an external geocoding service.

This GPS coordinate format converter accepts batches of latitude/longitude strings in decimal degrees (DD), degrees-minutes-seconds (DMS), and degrees-decimal-minutes (DDM). It detects the source notation, validates ranges, and returns every valid point in all three formats.

Invalid rows can remain in the output with stable error codes, making the Actor useful in GIS imports, logistics files, field-survey cleanup, and recurring ETL validation.

What this Actor does

For each supplied coordinate string, the Actor:

  1. separates the two coordinate components;
  2. detects DD, DMS, or DDM;
  3. resolves latitude/longitude order;
  4. applies N, S, E, and W hemisphere signs;
  5. validates latitude from -90 to 90;
  6. validates longitude from -180 to 180;
  7. converts the point to normalized DD;
  8. converts the point to normalized DMS;
  9. converts the point to normalized DDM;
  10. emits a typed validation result.

Processing is deterministic and offline. The Actor does not call a maps API, geocoder, website, proxy, or browser.

Who is it for?

  • GIS analysts cleaning mixed coordinate columns before an import.
  • Survey teams standardizing DMS observations from field notes.
  • Logistics teams validating depot or delivery coordinates.
  • Data engineers enforcing one coordinate format in an ETL pipeline.
  • Researchers normalizing points collected from multiple instruments.
  • No-code users converting a pasted list into an exportable Apify dataset.

Supported GPS coordinate formats

Input notationExampleDetected value
Decimal degrees (DD)40.7128, -74.0060decimal-degrees
Degrees-minutes-seconds (DMS)51° 30′ 26.64″ N, 0° 7′ 39.12″ Wdegrees-minutes-seconds
Degrees-decimal-minutes (DDM)33° 51.528′ S, 151° 12.558′ Edegrees-decimal-minutes
Longitude-first decimal-74.0060, 40.7128DD with coordinateOrder: lon-lat

Comma, semicolon, slash, and pipe separators are accepted. A simple unsigned decimal pair may also use whitespace.

The Actor converts notation on WGS84-style latitude/longitude values. It does not reproject coordinates between datums or EPSG coordinate reference systems.

Input parameters

FieldTypeDefaultDescription
coordinatesstring arrayrequiredOne coordinate pair per item; 1 to 10,000 items.
coordinateOrderstringautoauto, lat-lon, or lon-lat.
outputPrecisioninteger6Decimal places for formatted DD, DMS seconds, and DDM minutes; 0 to 10.
includeInvalidbooleantrueKeep rejected rows with error details.
maxItemsinteger20Maximum supplied rows processed in one run; increase up to 10,000 when needed.

auto uses hemisphere letters first. For unsigned values, a first component outside latitude range implies longitude-first; otherwise the Actor assumes latitude-first. Set an explicit order when your source stores longitude first.

Get started

  1. Open the Actor in Apify Console.
  2. Paste one or more strings into GPS coordinate strings.
  3. Leave Coordinate order on auto unless your unsigned source is longitude-first.
  4. Choose the desired output precision.
  5. Keep invalid rows enabled for data-quality audits.
  6. Click Start.
  7. Open the dataset and export JSON, CSV, Excel, XML, or another supported format.

Example input:

{
"coordinates": [
"40.7128, -74.0060",
"51° 30′ 26.64″ N, 0° 7′ 39.12″ W",
"33° 51.528′ S, 151° 12.558′ E"
],
"coordinateOrder": "auto",
"outputPrecision": 6,
"includeInvalid": true
}

Output fields

FieldMeaning
rowOne-based source position.
inputOriginal supplied text.
validWhether parsing and range checks passed.
detectedFormatDD, DMS, or DDM source notation.
detectedOrderResolved lat-lon or lon-lat order.
latitudeNumeric normalized latitude.
longitudeNumeric normalized longitude.
decimalDegreesFormatted normalized DD pair.
dmsFormatted normalized DMS pair.
ddmFormatted normalized DDM pair.
latitudeDms / longitudeDmsIndividual DMS components.
latitudeDdm / longitudeDdmIndividual DDM components.
inputPrecisionDecimal places in the most precise source component.
outputPrecisionRequested formatting precision.
errorCodeStable rejection code for invalid rows.
errorHuman-readable rejection reason.

Example valid result:

{
"row": 1,
"input": "40.7128, -74.0060",
"valid": true,
"detectedFormat": "decimal-degrees",
"detectedOrder": "lat-lon",
"latitude": 40.7128,
"longitude": -74.006,
"decimalDegrees": "40.7128, -74.006",
"dms": "40° 42′ 46.080000″ N, 74° 0′ 21.600000″ W",
"ddm": "40° 42.768000′ N, 74° 0.360000′ W",
"inputPrecision": 4,
"outputPrecision": 6,
"errorCode": null,
"error": null
}

Validation and per-row errors

When includeInvalid is true, bad rows do not hide inside logs. They appear in the same dataset with valid: false and one of these codes:

  • EMPTY_COORDINATE — the input is blank;
  • UNRECOGNIZED_FORMAT — the pair cannot be parsed as DD, DMS, or DDM;
  • AMBIGUOUS_ORDER — hemisphere labels do not identify one latitude and one longitude;
  • LATITUDE_OUT_OF_RANGE — normalized latitude exceeds ±90;
  • LONGITUDE_OUT_OF_RANGE — normalized longitude exceeds ±180.

Turn includeInvalid off when downstream consumers should receive valid rows only. Filtered invalid rows are not emitted and do not incur an item event.

How much does it cost to convert GPS coordinates?

The Actor uses pay-per-event pricing:

  • $0.001 per run start;
  • $0.002404 per emitted coordinate row on the BRONZE tier;
  • subscription tiers apply progressively lower per-row prices.

Typical BRONZE examples:

Emitted rowsEstimated total
1$0.003404
10$0.025040
100$0.241400
1,000$2.405000

The item charge covers both valid conversion rows and typed invalid-row results because each is usable data-quality output. Your active Apify plan determines the exact tier price shown before a run.

Accuracy and precision

The converter uses standard arithmetic:

decimal degrees = degrees + minutes / 60 + seconds / 3600

S and W produce negative values. Numeric latitude and longitude retain JavaScript number precision. outputPrecision controls only the formatted strings.

inputPrecision reports textual decimal places; it is not a promise of GPS measurement accuracy. A coordinate with many digits can still come from an inaccurate sensor.

Automation and integration ideas

  • Run after CSV ingestion to validate a coordinate column.
  • Schedule recurring cleanup of field-observation batches.
  • Send valid rows to a mapping or routing workflow.
  • Route invalid rows to a review queue using errorCode.
  • Compare normalized points across periodic dataset snapshots.
  • Export DDM strings for devices that require degrees and decimal minutes.

Apify integrations can send datasets to Google Sheets, Zapier, Make, webhooks, cloud storage, or your own API.

Run with the Apify API

Replace YOUR_TOKEN with an Apify API token.

cURL

curl -X POST \
"https://api.apify.com/v2/acts/automation-lab~bulk-gps-coordinate-format-converter/run-sync-get-dataset-items?token=YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"coordinates":["40.7128, -74.0060"],"coordinateOrder":"auto"}'

JavaScript

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: process.env.APIFY_TOKEN });
const run = await client.actor('automation-lab/bulk-gps-coordinate-format-converter').call({
coordinates: ['40.7128, -74.0060', '51° 30′ 26.64″ N, 0° 7′ 39.12″ W'],
includeInvalid: true,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Python

from apify_client import ApifyClient
client = ApifyClient('YOUR_TOKEN')
run = client.actor('automation-lab/bulk-gps-coordinate-format-converter').call(run_input={
'coordinates': ['-74.0060, 40.7128'],
'coordinateOrder': 'lon-lat',
'outputPrecision': 5,
})
items = client.dataset(run['defaultDatasetId']).list_items().items
print(items)

Use through MCP

Claude Code

claude mcp add --transport http apify \
"https://mcp.apify.com?tools=automation-lab/bulk-gps-coordinate-format-converter"

Use this equivalent MCP server configuration in the supported desktop and editor clients:

Claude Desktop

{
"mcpServers": {
"apify": {
"url": "https://mcp.apify.com?tools=automation-lab/bulk-gps-coordinate-format-converter"
}
}
}

Cursor

Add the same apify server object to Cursor's MCP settings.

VS Code

Add the same apify server URL through the VS Code MCP server configuration.

Example prompts:

  • “Convert these GPS points to decimal degrees and DMS, and keep invalid rows.”
  • “Treat this list as longitude-first and return five decimal places.”
  • “Normalize this mixed field survey batch and summarize the error codes.”

Limits and failure behavior

  • One run processes at most 10,000 supplied strings.
  • Both components in one row must use the same notation.
  • The Actor supports DD, DMS, and DDM only.
  • It does not support UTM, MGRS, geohash, Plus Codes, Maidenhead, or datum reprojection.
  • It does not geocode addresses or reverse-geocode points.
  • It does not calculate distance, bearing, midpoint, or bounding boxes.
  • Decimal commas inside a component are not supported because commas separate coordinate components.
  • Fatal top-level input errors fail the run with a non-zero status.
  • Row-level parse and range errors remain typed dataset records by default.

Legality, responsible use, and privacy

Coordinate conversion is generally a neutral data-processing activity. You are responsible for having permission to process and store the supplied location data.

Avoid uploading precise locations tied to private individuals unless you have a lawful purpose and appropriate safeguards. Review retention, access, and export settings for sensitive field, health, home, or infrastructure coordinates.

Because conversion is offline, coordinate strings are not shared with an external map or geocoding provider by this Actor. Standard Apify platform storage and account controls still apply.

Troubleshooting

Why was an unsigned pair interpreted as latitude first?

Auto mode assumes latitude-first when both numbers fit latitude range. Set coordinateOrder to lon-lat for GeoJSON-style or database longitude-first rows.

Why is my UTM or MGRS value rejected?

Those coordinate systems are outside this Actor's DD/DMS/DDM contract. Convert them to WGS84 latitude/longitude before running this Actor.

Why did fewer rows appear than I supplied?

Check maxItems. Also check whether includeInvalid is false, which omits rejected rows.

Does output precision improve location accuracy?

No. It changes formatting only and cannot add measurement accuracy to the source.

FAQ

Can I mix DD, DMS, and DDM in one run?

Yes. Detection happens independently for every row.

Can latitude and longitude use different formats in the same row?

No. Mixed-component notation is rejected to prevent silent guesses.

Can I export to CSV or Excel?

Yes. Use the dataset export controls or dataset API after the run.

Are invalid rows charged?

Only if they are emitted as typed results. Set includeInvalid to false to omit them.

Does the Actor need a proxy or API key?

No. It performs the conversion locally inside the Actor run.

Use this Actor for coordinate notation cleanup; use the related tools only when those separate workflow steps are needed.