What is KML File Compressor?
KML File Compressor is a privacy-first, browser-based tool that reduces the file size of KML, KMZ, GeoJSON, and ZIP archives containing geospatial data — with zero server uploads.
Unlike a simple KML-to-KMZ zip converter, this tool applies a multi-stage compression pipeline: it strips unnecessary XML whitespace, removes unused styles and descriptions, rounds coordinate decimal precision, and applies Turf.js-powered vertex simplification. Each stage is independently controlled by the compression level slider.
The result is typically 40–95% smaller files that load faster in Google Earth, Google Maps, ArcGIS Online, and QGIS — without visually distorting your map.
When Should You Use This Tool?
- •Your KML file exceeds Google My Maps' 5MB upload limit.
- •Google Earth lags or crashes when loading a complex boundary file.
- •You are sending a KML attachment by email and need to reduce its size.
- •You have a GeoJSON with millions of vertices from a national boundaries dataset.
- •You need to embed geographic data in a mobile app and every kilobyte matters.
- •You have a ZIP of 20 KML survey files that all need size-optimizing at once.
How to Use KML File Compressor
- Upload your KML, KMZ, GeoJSON, or ZIP file (multiple files supported).
- Move the Compression Level slider: Lossless (0%) strips whitespace only; Maximum (100%) removes styles, descriptions, rounds coordinates to 3 decimals, and simplifies vertices.
- Review the applied settings summary (coordinate decimals, simplification tolerance, and which metadata is stripped).
- Click "Compress Files" and wait a moment while the browser processes your data.
- Review the size reduction stats — original vs compressed vs reduction percentage.
- Click "Download" to save the compressed file in the same format as your input (or ZIP for multiple files).
Real-World Use Cases
GIS Professionals
Compress high-resolution boundary files (national/state borders, cadastral layers) before uploading to ArcGIS Online, Mapbox, or Leaflet web maps where file size affects load time and tile budget.
Mobile App Developers
Bundle compressed GeoJSON files inside Android or iOS apps. Every kilobyte saved reduces app download size. Use Maximum compression for background overlay layers where pixel-perfect accuracy isn't critical.
Drone & Survey Teams
Survey outputs often produce dense KML tracks with a vertex every 1 metre. Use Balanced compression to reduce these to a fraction of the size while keeping the shape accurate for area calculations and reporting.
Email & File Sharing
Email clients typically limit attachments to 10–25MB. Compress a 20MB KML to under 2MB in seconds without installing any software, then attach it directly to your email as a KMZ.
Supported Formats & Limits
- Input Formats: .kml, .kmz, .geojson, .json, .zip (containing any of the above)
- Multiple Files: Upload multiple files at once — output is a single .zip with all files compressed individually
- Output Formats: Same format as input for single files; .zip for multiple files; .kmz for single .kmz input
- Compression Stages: Whitespace removal → ExtendedData strip → Style strip → Coord precision rounding → Turf.js vertex simplification → ZIP/DEFLATE wrapping
- Privacy: 100% browser-based. Your files never leave your device — all compression runs in JavaScript using JSZip, Turf.js, and fast-xml-parser.
- File Size Limits: Files up to 100MB are supported. Very large files (50MB+) may take 5–10 seconds on lower-end devices.