KML (Keyhole Markup Language) and KMZ (compressed KML) are the standard file formats for Google Earth. If Google Earth refuses to open your file, the cause is usually a formatting issue, a corrupted download, or a file that is too large for the application to handle.
You do not need Google Earth just to check whether the file is valid. You only need a tool that understands the KML or KMZ format.
Open the KML Viewer or the KMZ Viewer to inspect a supported file directly in your browser.
What are KML and KMZ files?
KML and KMZ are geographic file formats originally developed by Keyhole (later acquired by Google) and used by Google Earth.
KML (.kml)
KML is an XML-based format for storing geographic data. A .kml file can contain:
- Placemarks - points with a name and description
- Lines and paths - connected line segments
- Polygons - filled shapes representing areas
- Ground overlays - images draped over the terrain
- Folders and documents - groups of features
- Styles - colors, icons, and line widths
- Network links - references to remote KML files
Because KML is plain XML, you can open it in a text editor, but the raw markup is not easy to read without a parser.
KMZ (.kmz)
KMZ is a compressed (zipped) version of one or more KML files, plus any embedded resources such as:
- Images (icons, overlays, photos)
- Models (3D buildings)
- Supplementary KML files
A .kmz file is a standard ZIP archive with a .kmz extension. Google Earth reads the compressed package and extracts the KML inside.
Why KML or KMZ files fail to open in Google Earth
Google Earth is generally reliable with KML and KMZ, but several common issues can prevent a file from opening:
- Corrupted file: A bad download or incomplete transfer can damage the file.
- Invalid XML: KML must be well-formed XML. A single syntax error can stop the parser.
- Unsupported KML version: Google Earth supports specific KML versions. Newer or custom extensions may not work.
- File too large: Very large KML or KMZ files can freeze or crash Google Earth.
- Broken KMZ archive: If the ZIP structure is damaged, Google Earth cannot extract the KML inside.
- Missing resources: A KMZ that references external images or models may fail if those resources are missing.
- Wrong file association: The file may open in another app instead of Google Earth.
The result is a file you received or exported but cannot view.
Quick answer: what should you do?
Choose the method based on what you actually need.
| What you need to do | Better approach |
|---|---|
| Quickly preview a KML or KMZ file | Use a KML or KMZ viewer |
| Check if the file is valid | Open it in a viewer that reports errors |
| View placemarks and polygons | Use a viewer with a map |
| Check the raw KML structure | Use a viewer that shows the XML source |
| Fix a corrupted KMZ | Re-download or repair the ZIP archive |
| Open a very large file | Use a viewer or a data tool instead of Google Earth |
| Convert to another format | Use a viewer with export support |
For a quick check, FileViewerHub is designed to show supported KML and KMZ file contents in your browser without requiring Google Earth.
Method 1: Open the KML or KMZ file in FileViewerHub
This method is useful when you need to preview the map, check features, or validate the file rather than use the full Google Earth interface.
Step 1: Open the KML or KMZ Viewer
Go to the FileViewerHub KML Viewer or the KMZ Viewer.
The viewers support .kml and .kmz files and process supported file contents locally in the browser for standard viewing.
Step 2: Select the file
Drag the file into the upload area or choose it from your device.
Before parsing begins, FileViewerHub may show a large-file warning when the file exceeds the recommended size for the current device. Files above the viewer's hard browser-safety limit should be blocked rather than opened.
This limit is intentional. A KML or KMZ file with many features can expand significantly after parsing.
Step 3: View the features on the map
After the file opens, verify that:
- Placemarks, lines, and polygons render on the map.
- Feature names and descriptions are shown.
- Colors and styles appear as expected.
- Folders and document structure are listed where supported.
- The geographic location is correct.
FileViewerHub can parse standard KML and KMZ files produced by Google Earth, mapping platforms, and GIS tools where supported.
Step 4: Check the feature list and properties
For a KML or KMZ file, the useful details are often in the feature properties rather than just the map.
Use the viewer to inspect:
- Feature names and descriptions
- Coordinates
- Style references (colors, icons, line widths)
- Folder hierarchy
- Extended data and custom attributes
If the feature list is empty or shows errors, the file may be corrupted or use an unsupported KML version.
Step 5: Check the raw KML source
If the viewer supports a raw or source view, inspect the underlying XML to check for:
- Missing closing tags
- Invalid characters
- Broken namespace declarations
- Unsupported elements
This is especially useful when Google Earth reports a parse error but does not tell you where the problem is.
Step 6: Export only what you need
If the viewer supports export for the current file, export the features to a more portable format such as GeoJSON or CSV.
You can then open the smaller result in:
- Another mapping tool
- A GIS application
- A spreadsheet
- Another program for sharing
This avoids forcing Google Earth to handle a file it cannot parse.
Method 2: Fix the file and reopen in Google Earth
If you want to continue using Google Earth, you can try to fix the file first.
Fix a KML file
- Open the
.kmlfile in a text editor (Notepad, TextEdit, or VS Code). - Look for obvious XML errors such as:
- Missing closing tags (for example,
<Placemark>without</Placemark>) - Unescaped characters such as
&instead of& - Broken namespace declarations in the root
<kml>element
- Missing closing tags (for example,
- Save the file and reopen it in Google Earth.
If the file is large, a text editor may struggle. Use a viewer that reports the error location instead.
Fix a KMZ file
- Rename the
.kmzfile to.zip. - Open the ZIP archive with a decompression tool.
- Check whether
doc.kmlor another KML file is present inside. - If the archive is damaged, re-download the original KMZ.
- If the KML inside is invalid, extract it, fix the XML, and repackage the ZIP.
- Rename the repaired ZIP back to
.kmz. - Open it in Google Earth.
Limitations
- Fixing XML by hand is error-prone for large files.
- KMZ archives with custom resources may not repackage cleanly.
- Google Earth may still reject the file if the KML version is unsupported.
Method 3: Use another mapping application
If Google Earth cannot open the file, another mapping tool may succeed.
Options include:
- Browser-based viewer: Open the KML or KMZ Viewer in any browser. No installation required.
- GIS software: QGIS and other desktop GIS tools can import KML and KMZ.
- Online mapping platforms: Some web mapping tools accept KML uploads.
- Mobile mapping apps: Some hiking and navigation apps can import KML files.
This is the better option when Google Earth consistently fails but the file is valid.
What if the KML or KMZ file still won't open?
Even with a viewer, some files can be difficult to read. Common causes include:
1. The file is corrupted
KML and KMZ files can be corrupted during download, email transfer, or cloud sync.
Symptoms include:
- Parser errors
- Missing features
- Truncated content
- A KMZ that cannot be unzipped
If you suspect corruption, try to obtain a fresh copy of the file from the original source.
2. The KML is not well-formed XML
KML is XML. A single syntax error can stop the parser. Common XML problems include:
- Missing closing tags
- Unescaped
&,<, or>characters - Incorrect attribute quoting
- Invalid namespace declarations
A viewer that reports the error location can help you find and fix the problem.
3. The KMZ archive is damaged
A KMZ file is a ZIP archive. If the ZIP structure is damaged, no tool can extract the KML inside.
Symptoms include:
- The file cannot be unzipped
- The archive appears empty
- The decompression tool reports a CRC error
If the archive is damaged, re-download the original KMZ.
4. The file uses an unsupported KML version
KML has evolved through several versions (2.0, 2.1, 2.2, 2.3). Google Earth supports most versions, but some tools produce KML with custom extensions or newer features that Google Earth does not understand.
If the viewer shows partial content, the file may use extensions that the parser does not fully support.
5. The file references missing resources
A KMZ file can reference embedded images, models, or external network links. If those resources are missing or the links are broken, Google Earth may fail to render the file correctly.
Symptoms include:
- Missing ground overlays
- Broken icons
- Missing 3D models
- Network link errors
Check the KMZ contents to confirm all referenced resources are present.
6. The file is very large
A KML or KMZ file with thousands of features can be very large. Google Earth may freeze or crash when loading a very large file.
If the file is large, check whether you need the entire file or just a subset of features.
7. The file is not actually a KML or KMZ file
Some files use the .kml or .kmz extension but are not valid KML or KMZ. For example, a renamed file or a file from another application may carry the extension without the correct internal structure.
If the viewer cannot parse the file, check the source and confirm it was produced by Google Earth or a compatible GIS tool.
How to open a KML or KMZ file on Windows
On Windows, if Google Earth is not installed or the file will not open, options include:
- Browser-based viewer: Open the KML or KMZ Viewer in Edge, Chrome, or Firefox. No installation required.
- Install Google Earth: Download Google Earth Pro for desktop from Google.
- GIS software: Use QGIS or another desktop GIS tool to import the file.
- Text editor: For KML only, open the file in a text editor to inspect the XML (not practical for large files).
For a quick preview on Windows, a browser-based viewer is usually the fastest option.
How to open a KML or KMZ file on Mac
On Mac, options include:
- Browser-based viewer: Open the KML or KMZ Viewer in Safari, Chrome, Edge, or Firefox. No installation required.
- Install Google Earth: Download Google Earth for Mac from Google.
- GIS software: Use QGIS for Mac or another GIS tool.
- TextEdit: For KML only, open the file in TextEdit to inspect the XML (not practical for large files).
For a quick preview on Mac, a browser-based viewer is usually the fastest option.
How to open a KML or KMZ file on iPhone or Android
On mobile, Google Earth is available as an app, but it may not open all KML or KMZ files.
Options include:
- Browser-based viewer: Open the KML or KMZ Viewer in your mobile browser. No installation required.
- Google Earth app: Open the file in the Google Earth mobile app.
- Mobile mapping apps: Some hiking and navigation apps can import KML files.
For a quick preview on mobile, a browser-based viewer is usually the fastest option.
KML vs KMZ: which format do you have?
If you are unsure which format your file uses, check the extension:
| Extension | Format | Contents | How to open |
|---|---|---|---|
.kml | Keyhole Markup Language | Plain XML text | Any KML viewer or text editor |
.kmz | Compressed KML | ZIP archive containing KML and resources | A KMZ viewer or a decompression tool |
If the file has no extension, check the source. A KML file starts with <?xml and <kml; a KMZ file is a binary ZIP archive.
A viewer that supports both formats can usually detect the correct type automatically.
Is it safe to open a KML or KMZ file in an online viewer?
KML and KMZ files can contain location data, which may reveal sensitive places, home addresses, or business locations.
For standard viewing, FileViewerHub processes supported KML and KMZ file contents locally in your browser rather than uploading the file to FileViewerHub servers.
You should still:
- Use a device you trust.
- Avoid opening files from unknown sources.
- Review the file before sharing it with someone else.
- Be aware that KMZ files can contain embedded images or models with their own metadata.
Limited technical diagnostics may be processed when a viewer fails, but diagnostic logging should exclude filenames and file contents.
KML/KMZ viewer vs Google Earth: which should you use?
Use a KML or KMZ viewer when your main goal is:
- Quick preview
- Validating whether the file is well-formed
- Checking features and properties
- Viewing the raw XML source
- Opening a file without installing Google Earth
- Converting to another format
Use Google Earth when you need:
- 3D terrain and imagery
- Full Google Earth navigation
- Time animation and historical imagery
- Network links and live data
- The full Google Earth feature set
Use a GIS tool when you need:
- Advanced spatial analysis
- Coordinate system transformations
- Large-scale data processing
- Integration with other GIS formats
The tools solve different problems. A KML or KMZ viewer does not need to replace Google Earth to be useful; it can help you verify the file before deciding whether to fix it or reopen it in Google Earth.
