You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Photon is a fast, open-source geocoding service built by komoot.
It uses OpenStreetMap data and stores it in an embedded Elasticsearch index for search.
This guide explains how to import Photon datasets (JSONL dumps) into your own Reitti / Photon instance — for example, for Switzerland & Liechtenstein.
🌍 1. Choose a Dataset
Photon provides preprocessed JSONL dumps for each region.
You can browse available regions here:
✅ Use the 0.7.x dump when running Photon 0.7.x (Elasticsearch backend).
The master dumps are for the latest development versions and may not be compatible.
🧰 2. Download and Import the Data
Run the following commands to download and import the JSONL dump.
Increase your HDD/SSD Space for the LXC before, the files are really big.
It is recommended to write everything to an SSD or NVME.
You can increase the CPU to 4+ and RAM/SWAP to 4+, for faster Imports.
# Stop Photon if it's already running
systemctl stop photon
# Create target directories
mkdir -p /opt/photon
cd /opt/photon
# Download the latest Switzerland+Liechtenstein dump (0.7.x)
curl -fsSL -o photon-dump-switzerland-liechtenstein.jsonl.zst https://download1.graphhopper.com/public/europe/switzerland-liechtenstein/photon-dump-switzerland-liechtenstein-0.7-latest.jsonl.zst
# Import into Photon (creates photon_data index) -- This takes some Minutes!
zstd --stdout -d photon-dump-switzerland-liechtenstein.jsonl.zst | java --enable-native-access=ALL-UNNAMED -Xmx4g -jar photon.jar -nominatim-import -import-file - -data-dir /opt/photon -languages de,en,fr,it
# Remove dump to save space
rm -f photon-dump-switzerland-liechtenstein.jsonl.zst
# Start Photon
systemctl start photon
🟢 Tip: The .jsonl.zst dumps are fully compatible with Elasticsearch/OpenSearch-based Photon releases ≥ 0.7.
Always match the dump version to your Photon binary (0.7.x ↔ photon-0.7.x.jar).
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
🗺️ Importing Data into Photon
Photon is a fast, open-source geocoding service built by komoot.
It uses OpenStreetMap data and stores it in an embedded Elasticsearch index for search.
This guide explains how to import Photon datasets (JSONL dumps) into your own Reitti / Photon instance — for example, for Switzerland & Liechtenstein.
🌍 1. Choose a Dataset
Photon provides preprocessed JSONL dumps for each region.
You can browse available regions here:
Example (Switzerland & Liechtenstein):
You’ll typically see entries like:
0.7.xphoton-dump-switzerland-liechtenstein-0.7-latest.jsonl.zst🧰 2. Download and Import the Data
Run the following commands to download and import the JSONL dump.
Increase your HDD/SSD Space for the LXC before, the files are really big.
It is recommended to write everything to an SSD or NVME.
You can increase the CPU to 4+ and RAM/SWAP to 4+, for faster Imports.
After this import, you’ll have:
🔎 3. Test the API
Once running, you can query Photon’s REST API:
curl "http://127.0.0.1:2322/api?q=zurich"Example response:
{ "features": [ { "geometry": { "coordinates": [8.55, 47.36667] }, "properties": { "name": "Zürich", "country": "Switzerland", "osm_id": 240109189, "osm_type": "N", "extent": [8.4, 47.5, 8.7, 47.3] } } ] }🧹 4. Notes & Maintenance
-languages de,en,fr,it,...).-Xmxto at least 8–12 GB.🧭 Example: Full One-liner Import
🧩 Related Links
Beta Was this translation helpful? Give feedback.
All reactions