npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

google-photos-fixer

v1.0.0

Published

Fix dates and GPS in your Google Photos Takeout export. Embeds JSON metadata into photos and videos using ExifTool.

Readme

📷 google-photos-fixer

Fix wrong dates and missing GPS in your Google Photos Takeout export — in one command.

License: MIT Node.js Platform


The Problem

When you export your photos from Google Photos using Google Takeout, the dates and GPS coordinates are not stored inside the photo files. Instead, Google puts them in separate .json sidecar files sitting next to each photo. This means:

  • Photos appear with wrong dates when imported into Apple Photos, Windows Photos, Lightroom, or any other app
  • GPS locations are lost
  • Edited photos (with -edited suffix) lose their metadata entirely

google-photos-fixer reads all those JSON files and writes the correct metadata back into your photos, permanently and reliably.


✨ Features

  • 🖱️ Interactive wizard — just run it with no arguments, answer 3 questions, done
  • 📅 Fixes DateTimeOriginal, CreateDate and ModifyDate
  • 📍 Restores GPS coordinates (latitude, longitude, altitude)
  • ✏️ Handles edited photos (-edited, -edytowano, -EFFECTS, and more)
  • 📦 Supports both Takeout formats (old .json and new .supplemental-metadata.json)
  • 🎬 Works with photos and videos: JPG, PNG, HEIC, MP4, MOV, and more
  • 🔍 Dry-run mode — preview what would happen without touching files
  • Fast — parallel processing (8 workers by default)
  • 🪶 Zero dependencies — only Node.js built-ins + ExifTool
  • 🪟🍎🐧 Cross-platform: Windows, macOS, Linux

Requirements

Install ExifTool

| Platform | Command | |---|---| | Windows | winget install OliverBetz.ExifTool | | macOS | brew install exiftool | | Linux | sudo apt install libimage-exiftool-perl |

Windows users: ExifTool bundled with ShareX is also detected automatically.


Installation

Option A — Run directly (no install needed)

npx google-photos-fixer

Option B — Install globally

npm install -g google-photos-fixer
gpf

Option C — Clone and run

git clone https://github.com/MajkiHA/google-photos-fixer.git
cd google-photos-fixer
node bin/cli.js

Usage

🖱️ Interactive Wizard (recommended for beginners)

Just run with no arguments — the program will guide you through every step:

gpf
  ╔══════════════════════════════════════════════════════╗
  ║        google-photos-fixer  v1.0.0                   ║
  ║   Fix dates & GPS in your Google Photos Takeout      ║
  ╚══════════════════════════════════════════════════════╝

  Step 1/4 — Checking ExifTool...
  ✔ Found: C:/Program Files/ExifTool/exiftool.exe

  Step 2/4 — Google Photos Takeout folder
  > Input folder path: C:\Downloads\Takeout\Google Photos

  Step 3/4 — Output folder
  > Output folder path: C:\Photos-Fixed

  Step 4/4 — Scanning files...

  ┌─────────────────────────────────────┐
  │  Files found      : 13044           │
  │  With metadata    : 11675           │
  │  Without metadata : 1369            │
  │  Output folder    : C:\Photos-Fixed │
  └─────────────────────────────────────┘

  Start processing? [Y/n]:

⌨️ Command Line (for advanced users)

# Basic usage
gpf --input "C:/Takeout/Google Photos" --output "C:/Photos-Fixed"

# Preview without copying files
gpf --input ./Takeout --output ./Output --dry-run

# Custom exiftool path
gpf -i ./Takeout -o ./Output --exiftool "D:/tools/exiftool.exe"

# Adjust parallel workers
gpf -i ./Takeout -o ./Output --concurrency 4

| Flag | Description | Default | |---|---|---| | -i, --input | Google Photos folder | required | | -o, --output | Output folder | required | | -e, --exiftool | Path to exiftool binary | auto-detected | | -c, --concurrency | Parallel workers | 8 | | --dry-run | Preview, no files written | false | | -v, --version | Show version | | | -h, --help | Show help | |


How It Works

  1. Scans the input folder recursively for media files
  2. Pairs each file with its JSON sidecar (handles both Takeout formats)
  3. Copies the file to the output folder (originals are never modified)
  4. Reads the JSON: date taken, GPS, description
  5. Writes the metadata into the copy using ExifTool
Takeout/
  Google Photos/
    My Album/
      photo.jpg          ← copied to Output
      photo.jpg.json     ← read for metadata

Supported File Types

| Type | Extensions | |---|---| | Photos | .jpg .jpeg .png .gif .webp .bmp .tiff .heic .heif | | Videos | .mp4 .mov .avi .mkv .m4v .3gp .wmv .mts .m2ts |


Known Limitations

| Issue | Explanation | |---|---| | AVI files | ExifTool cannot write metadata to RIFF AVI format. Files are copied, metadata skipped. | | Corrupted MP4s | Some Takeout exports contain slightly malformed MP4 files. They are copied successfully; only metadata embedding fails. | | Files without JSON | A small number of files may lack a JSON sidecar. They are copied as-is with their original embedded metadata (if any). |


Troubleshooting

ExifTool not found Install ExifTool (see Requirements) or pass its path with --exiftool.

Photos still show wrong dates after import Some apps (iCloud, Google Drive) ignore EXIF dates. Try importing directly into the app from the Output folder, not syncing via a cloud folder.

"Access denied" on Windows Run the terminal as Administrator, or choose an output folder where you have write permissions.


License

MIT © MajkiHA


☕ Support

If this tool saved you hours of work, consider buying me a coffee!

Buy Me A Coffee



🇵🇱 Polski / Polish

Problem

Gdy eksportujesz zdjęcia z Google Photos przez Google Takeout, daty i lokalizacje GPS nie są zapisane w plikach zdjęć — trafiają do osobnych plików .json. Przez to po imporcie zdjęcia mają złe daty i brak lokalizacji.

google-photos-fixer odczytuje te pliki JSON i zapisuje poprawne metadane bezpośrednio w plikach zdjęć.

Instalacja

# Opcja 1 — bez instalacji
npx google-photos-fixer

# Opcja 2 — globalnie
npm install -g google-photos-fixer
gpf

Wymagane: Node.js 18+ i ExifTool

  • Windows: winget install OliverBetz.ExifTool
  • macOS: brew install exiftool
  • Linux: sudo apt install libimage-exiftool-perl

Użycie

Uruchom bez argumentów — program przeprowadzi Cię krok po kroku:

gpf

Lub z argumentami:

gpf --input "C:/Takeout/Google Photos" --output "C:/Zdjecia-Naprawione"

Co robi program

  1. Skanuje folder wejściowy w poszukiwaniu zdjęć i filmów
  2. Paruje każdy plik z odpowiednim plikiem JSON
  3. Kopiuje plik do folderu wyjściowego (oryginały nigdy nie są modyfikowane)
  4. Wpisuje poprawną datę, GPS i opis do kopii przez ExifTool

Obsługiwane formaty

Zdjęcia: JPG, PNG, HEIC, WebP i inne
Filmy: MP4, MOV, MKV i inne
Obsługuje oba formaty Takeout: .json i .supplemental-metadata.json
Obsługuje zdjęcia edytowane: -edytowano, -EFFECTS itp.


☕ Jeśli narzędzie Ci pomogło — postaw kawę!