PHPackages                             kicken/osm-parser - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. kicken/osm-parser

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

kicken/osm-parser
=================

Library for parsing OSM data dump files.

164PHP

Since Sep 28Pushed 2y ago1 watchersCompare

[ Source](https://github.com/kicken/osm-parser)[ Packagist](https://packagist.org/packages/kicken/osm-parser)[ RSS](/packages/kicken-osm-parser/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

PHP OSM Data file parser
========================

[](#php-osm-data-file-parser)

Parse Open Street Map XML or PBF files with a simple iterator interface.

Example
-------

[](#example)

Extract all named nodes from the [Austin, TX dump](https://download.bbbike.org/osm/bbbike/Austin/).

```
$iter = new Kicken\OSMParser\Parser\XML('Austin.osm');
foreach ($iter as $entity){
    if ($entity instanceof Kicken\OSMParser\Data\Node && $entity->getTag('name')){
        echo "\t", $entity->getTag('name'), ' @ (', $entity->getLat(), ',', $entity->getLon(), ')', PHP_EOL;
    }
}

```

Resource requirements
---------------------

[](#resource-requirements)

While PBF files are much smaller on disk, they require **significantly** more resources to parse. I tested both parsers using the example code above using PHP 8.2.3 on a Intel i7-1260P laptop and had the following results:

ParserTimePeak memory usageXML1m 01s4.1 MBPBF (Native)0m 41s3.1 GBPBF (PHP)3m 23s3.9 GBXML format is quick and uses the least amount of memory since it can stream as they are found rather than loading a bunch into memory. PBF format is quick if you use the native extension, but requires much more memory as many nodes must be loaded into memory first then output. PBF without the native extension is slow and uses a lot of memory and thus should be avoided.

###  Health Score

16

—

LowBetter than 5% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity10

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity23

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/93485c3a28acd5b5cc4649ef8081907889270d7c7a2832fa8aa19e31f9c688ac?d=identicon)[kicken](/maintainers/kicken)

---

Top Contributors

[![kicken](https://avatars.githubusercontent.com/u/6234547?v=4)](https://github.com/kicken "kicken (11 commits)")

### Embed Badge

![Health badge](/badges/kicken-osm-parser/health.svg)

```
[![Health](https://phpackages.com/badges/kicken-osm-parser/health.svg)](https://phpackages.com/packages/kicken-osm-parser)
```

###  Alternatives

[masterminds/html5

An HTML5 parser and serializer.

1.8k242.8M229](/packages/masterminds-html5)[sabberworm/php-css-parser

Parser for CSS Files written in PHP

1.8k191.2M65](/packages/sabberworm-php-css-parser)[jms/metadata

Class/method/property metadata management in PHP

1.8k152.8M88](/packages/jms-metadata)[jms/serializer-bundle

Allows you to easily serialize, and deserialize data of any complexity

1.8k89.3M627](/packages/jms-serializer-bundle)[hassankhan/config

Lightweight configuration file loader that supports PHP, INI, XML, JSON, and YAML files

97513.5M170](/packages/hassankhan-config)[meyfa/php-svg

Read, edit, write, and render SVG files with PHP

54613.9M42](/packages/meyfa-php-svg)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
